<?xml version="1.0" encoding="utf-8" ?><rss version="2.0" xml:base="https://www.webmaster-forums.net/crss/node/1043461" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title></title>
    <link>https://www.webmaster-forums.net/crss/node/1043461</link>
    <description></description>
    <language>en</language>
          <item>
    <title>benf wrote:
What i didnt</title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/using-innerhtml-add-page-elements-over-appendchild#comment-1239978</link>
    <description> &lt;p&gt;&lt;div class=&quot;quote-msg&quot;&gt;&lt;div class=&quot;quote-author&quot;&gt;&lt;em&gt;benf&lt;/em&gt; wrote:&lt;/div&gt;What i didnt realise is that IE needs a tbody in the table otherwise it will show nothing!&lt;/div&gt;&lt;/p&gt;
&lt;p&gt;Yet another good argument against using tables for layout (unless you are presenting tabular data)&lt;/p&gt;
&lt;p&gt;I would say that innerHTML (remember the capital L!) is a good choice for dynamic techniques after the page loads, but constructing the elements with JS or standard HTML is better at the time of the page rendering.&lt;/p&gt;
&lt;p&gt;Note also that assigning the innerHTML after the page loads could result in a delay in displaying the content, depending on the amount of code being executed.&lt;/p&gt;
 </description>
     <pubDate>Wed, 01 Apr 2009 02:28:44 +0000</pubDate>
 <dc:creator>decibel.places</dc:creator>
 <guid isPermaLink="false">comment 1239978 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title>Yes looks like it?? Anyway</title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/using-innerhtml-add-page-elements-over-appendchild#comment-1239977</link>
    <description> &lt;p&gt;Yes looks like it?? Anyway got this to work using createElement. What i didnt realise is that IE needs a tbody in the table otherwise it will show nothing!&lt;/p&gt;
 </description>
     <pubDate>Tue, 31 Mar 2009 23:33:34 +0000</pubDate>
 <dc:creator>benf</dc:creator>
 <guid isPermaLink="false">comment 1239977 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title>benf wrote:
Hi Ben
Been</title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/using-innerhtml-add-page-elements-over-appendchild#comment-1239967</link>
    <description> &lt;p&gt;&lt;div class=&quot;quote-msg&quot;&gt;&lt;div class=&quot;quote-author&quot;&gt;&lt;em&gt;benf&lt;/em&gt; wrote:&lt;/div&gt;Hi Ben&lt;/div&gt;Been working too hard? &lt;img src=&quot;https://www.webmaster-forums.net/misc/smileys/grin.png&quot; title=&quot;Laugh&quot; alt=&quot;Laugh&quot; class=&quot;smiley-content&quot; /&gt;&lt;/p&gt;
 </description>
     <pubDate>Tue, 31 Mar 2009 13:38:00 +0000</pubDate>
 <dc:creator>greg</dc:creator>
 <guid isPermaLink="false">comment 1239967 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title>Hi Ben,
What i have done</title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/using-innerhtml-add-page-elements-over-appendchild#comment-1239965</link>
    <description> &lt;p&gt;Hi Ben,&lt;/p&gt;
&lt;p&gt;What i have done above is just for demonstration purposes. I have many more rows and more text and images to insert.&lt;/p&gt;
&lt;p&gt;Are there any compatibility problems with innerHTMl as apposed to createElement or vise verser?&lt;/p&gt;
 </description>
     <pubDate>Tue, 31 Mar 2009 13:32:33 +0000</pubDate>
 <dc:creator>benf</dc:creator>
 <guid isPermaLink="false">comment 1239965 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title>Hi Ben,
I depends on your</title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/using-innerhtml-add-page-elements-over-appendchild#comment-1239918</link>
    <description> &lt;p&gt;Hi Ben,&lt;/p&gt;
&lt;p&gt;I depends on your situation.&lt;/p&gt;
&lt;p&gt;Using the innerHTML property is handy for changing the content of an element on load or dynamically - but it assumes that the element has been created with HTML; the table always exists in the document.&lt;/p&gt;
&lt;p&gt;(note: your code &lt;code&gt;div.innerHTMl&lt;/code&gt; is not well-formed: the &quot;L&quot; should be capitalized, and this code will only work if you add an id to a div: &lt;code&gt;&amp;lt;div id=&amp;quot;div&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;/code&gt; - but I would not recommend using &quot;div&quot; for the id... typically the innerHTML property is accessed as follows: &lt;code&gt;document.getElementById(&amp;#039;mydiv&amp;#039;).innerHTML = &amp;quot;&amp;lt;table&amp;gt;&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;this is innerHTML&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&amp;lt;/table&amp;gt;&amp;quot;;&lt;/code&gt;)&lt;/p&gt;
&lt;p&gt;Creating the elements and appending them is a good method to use when the table may or may not exist depending on some programmatic condition, so it is not even created unless used. I think you still need to assign the content of the cell with the innerHTML property...&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Another question&lt;/strong&gt; is why are you creating a one row one column table within a div? You can just put your text in the div...&lt;/p&gt;
 </description>
     <pubDate>Sun, 29 Mar 2009 21:42:41 +0000</pubDate>
 <dc:creator>decibel.places</dc:creator>
 <guid isPermaLink="false">comment 1239918 at https://www.webmaster-forums.net</guid>
  </item>
  </channel>
</rss>
