Derek, have a read through http://devedge.netscape.com/viewsource/2003/xhtml-style-script/
...but to answer the question quickly: it should work if you use //<![CDATA[ //]]> Patrick ________________________________ Patrick H. Lauke Webmaster / University of Salford http://www.salford.ac.uk > -----Original Message----- > From: Derek Featherstone [mailto:[EMAIL PROTECTED] > Sent: 09 July 2004 16:28 > To: [EMAIL PROTECTED] > Subject: RE: [WSG] Internal CSS in XHTML served as > application/xhtml+xml > > > Roger wrote: > > Anyway, I was wondering if, and how, other people hide > internal CSS in > > XHTML documents from user agents that don't support CSS. > Note that this > > is about cases when moving the CSS to an external file is not an > > option, for whatever reason. > > On a related note -- I recently setup content negotiation on > WATS.ca to > serve our XHTML as application/xhtml+xml and most of the site > worked fine. > The one spot where it failed was with inline JavaScript -- we have a > resources page ( http://www.wats.ca/resources/testingtools/44 ) that > contains many JS bookmarklets which then caused loads of > parsing errors, and > they don't display in gecko based browsers... > > Normally, I would move all the JS to an external file as > well, but in this > case, it doesn't really make sense. I considered moving the > JS for each > bookmarklet to its own .js file, but that eliminates the > utility and ease > with which someone can drag and drop the bookmarklet onto > their bookmarks > bar in their browser, so isn't an acceptable solution. So, > I'm looking for a > way to escape inline javascript, and not really sure if there are any > solutions to that problem... > > Thoughts on this would be appreciated as well... I could futz > about with our > system to always serve that page as text/html, but would > prefer to send it > as application/xhtml+xml if I can. > > Best regards, > Derek. > -- > Derek Featherstone [EMAIL PROTECTED] > phone: 613.599.9784; toll-free: 1.866.932.4878 (North America) > Web Accessibility: http://www.wats.ca > Web Development: http://www.furtherahead.com > Personal: http://www.boxofchocolates.ca > > ***************************************************** > The discussion list for http://webstandardsgroup.org/ > See http://webstandardsgroup.org/mail/guidelines.cfm > for some hints on posting to the list & getting help > ***************************************************** > > ***************************************************** The discussion list for http://webstandardsgroup.org/ See http://webstandardsgroup.org/mail/guidelines.cfm for some hints on posting to the list & getting help *****************************************************
