This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

generating xhtml with msxml3


Hi list,

I'm trying to generate w3 compliant xhtml using msxml3 sp1. There's a
couple of problems I've come across:

1) if xsl:output is set to 'html' msxml adds a meta tag with
'content-type' and 'encoding' attributes directly after the 'head'
element; as the XSLT spec apparently says. However the xhtml spec says the
first element after 'head' must be 'title'??

2) With the output set to xml I can get round the above problem but get an
xml processing instruction as the first line - which also compromises the
w3 xhtml spec - doctype should be the first tag.

3) Regardless of what encoding methods I specify, and where (source doc,
stylesheet, asp page) msxml insists on adding 'encoding="utf-16"' - which
throws IE5 into fits with entities like é (defined in my DTD) -
every other browser seems to be able to cope though. How do I stop this -
the MS site is strangely silent on the subject...

I've currently worked around (2) & (3) by writing the transformation
results to a string and then chopping off the PI, but this is crap. Any
better ideas?

Also, ideally I'd like to be able to parameterise the doctype-system and
doctype-public attributes; i.e. have one stylesheet that can generate w3
compatible html4 or xhtml depending on a parameter passed to it. I'm
currently having to use 2 almost identical stylesheets. My only though so
far is to stack them - have all common elements in one module, the output
of which is passed to either the html4 or xhtml1 specific stylesheet
afterwards. I did find a similar question on DaveP's FAQ but couldn't
understand the answer... Any better ideas?

TIA,

Paul Bryant

smime.p7s


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]