One of the things the book repeatedly says is:
(and others like:
to filter out all the browser who are in fact not supporting DOM.
As I'm using Safari (and Firefox for testing purpose) the 'document.getElementById()' and therefore: DOM is supported.
as simple as:
the document.write doesn't get executed.
Now: I found a simple solutions which seems to work.... partially:
if(document.getElementById() == "undefined") return;
I could just omit the if statements to make it work altogether.
But that doesn't sound like the best method to me, because (so I've read)
it can crash browsers and such.
Is there a way to make the if(!document.getElementById()) work?
Thanks in advance for any help :)