On Wed, 16 Feb 2005 10:08:15 -0400, The Snider's Web <[EMAIL PROTECTED]> wrote:

<script type="text/javascript" src="http://www.statcounter.com/counter/counter_xhtml.js";></script><noscript><div class="statcounter"><a class="statcounter" href="http://www.statcounter.com/";><img class="statcounter" src="http://c5.statcounter.com/counter.php?sc_project=XXXXXXX&amp;amp;java=0&amp;amp;security=XXXXXXX"; alt="free web site hit counter" /></a></div></noscript>
<!-- End of StatCounter Code -->

What do you think?

It won't work with XHTML served as XHTML (application/xhtml+xml). If you serve XHTML as HTML tagsoup (text/html), it will.

The script:
http://www.statcounter.com/counter/counter_xhtml.js

relies on document.writeln, which is part of old Netscape "DOM",
and is not supported anymore in XML documents.

This is a difficult problem. document.createElement
should be used instead, but it has small and buggy support,
so ideally counter should first try innerHTML (IE prefers that),
then document.createElement (but not in Opera 6, IIRC) and finally
fall back to document.write supported by browsers that don't support XML.

PPK (www.quirksmode.org) should have some interesting info on this...

--
regards, Kornel Lesiński

******************************************************
The discussion list for  http://webstandardsgroup.org/

See http://webstandardsgroup.org/mail/guidelines.cfm
for some hints on posting to the list & getting help
******************************************************



Reply via email to