Forum Moderators: open
I'm new here...
I made a code that works perfectly fine in IE, but not Firefox.
After a little research, I found that the problem was "insertadjacenthtml"...Firefox doesn't support that.
Here's my code:
<script>
moduletitle = 'Title Here';
modulebody = 'Module Content';
sub = subTitle.parentNode.parentNode.parentNode.parentNode.parentNode
sub.insertAdjacentHTML('beforeBegin','<table border="1" cellspacing="0" cellpadding="4" width="100%" class="left"><tr><th valign="top" align="left" class="left">' + moduletitle + '</th></tr><tr><td valign="top" class="left">' + modulebody)
sub.insertAdjacentHTML('beforeBegin','<BR>');
</script>
It doesn't work in Firefox.
Do yall know of any substitute I can stick in there in place of insertadjacenthtml?
Thanks,
-Josh
You're right, insertadjacenthtml is a proprietary Microsoft method. It's non-standard (not in ECMAscript) and so not supported in other browsers. I found an older article with a generic workaround for Netscape 6 and Mozilla (of that time). I believe this approach would still work in versions since then.
[faqts.com...]