I wanted to set an onload function and tried this after appendChild(node)
node.setAttribute(attributename, value, [iecaseflag])
But, couldn't get it to work and it was easier to to have document.write('<img src="'+Q[i]+'" onload="nextFunc()"> ')
So I dunno. Guess I'm stuck with methods that will not be supported someday?
On the contrary, those methods (DOM methods) are the modern one. Can we see you code? Should work, unless you were made a mistake.
innerHTML could be also an alternative. But it depends on the aim of your code. innerHTML is not a standard DOM method and it does not insert always all the elements and their attributes into the DOM tree. If you need a simple display of new elements (and no further DOM manipulation) you may use innerHTML. Otherwise you are forced to use DOM methods.