Hi,
Is it possible to have something like the following?
Thanks for any ideas.Code:document.VARIABLE1.style.VARIABLE2 = (some color);
| SitePoint Sponsor |


Hi,
Is it possible to have something like the following?
Thanks for any ideas.Code:document.VARIABLE1.style.VARIABLE2 = (some color);

Code:document[variable1].style[variable2] = some_color;
Stephen J Chapman
javascriptexample.net, Book Reviews, follow me on Twitter
HTML Help, CSS Help, JavaScript Help, PHP/mySQL Help, blog
<input name="html5" type="text" required pattern="^$">


SOLVED.
Thanks for the reply. I also tried that before but it didn't work because both "document" and "style" are not arrays as far as I know. Anyway, I solved this by replacing my code with jQuery.
Bookmarks