RE: Any samples of client-side XSLT to generate webpag
Thanks for your reply. >-----Original Message----- >From: David Carlisle [mailto:davidc@xxxxxxxxx] >Sent: Tuesday, 27 July, 2004 11:49 PM >To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx >Subject: Re: Any samples of client-side XSLT to generate webpages? > > > (2) http://126.96.36.199:18080/shatteredspace/login.do?transform=true > - works in Mozilla - currently need to manually add the '?transform=true', > but I might automate this later > - nothing visible (except background graphic) in IE > >well this one is the easier of the two, probably >this one is an XHTML document served as text/html (no client side xslt) >so it will be handled by mozilla and IEs _HTML_ parser as such, things >like <td class="box_right"/> <br/> etc >(any instance of /> ) are all syntax errors and so whatever the browser >does is just dependent on its error recovery, so its not surprising if >you get differing effects. > >If you are generating html on the server, make sure your XSLT at that >end is generating _html_ (it will do this automatically if the top level >element is <html> in no-namespace). Should I change the content type to "application/xhtml+xml"? I was told that this is not fully supported by browsers. I would like to keep it as XHTML. This is why I keep the 'method="xml"' in my XSLT stylesheet. <xsl:output method="xml" version="1.0" encoding="iso-8859-1" indent="no" doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN" doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/> How do most people diplay XHTML (in a IE and Mozilla compliant style)? >(1) http://188.8.131.52:18080/shatteredspace/login.do > - works in IE > - unable to submit form in Mozilla > > >This one is a bit harder It's served as text/xml (application/xml is >better) and claims to be (and is) utf-8 in its xml declaration. > >the trouble is (I think, couldn't really check from here), after the >client side transform it's whatever encoding it's in after the transform >I understand that browsers are a little variable in what encoding they >use to return form data in these situations. When you say unable to >submit form in Mozilla do you mean that you don't get back the login >info that you expected or that you get nothing back, it may be worth >looking if you get data back in an unexpected encoding. I will change my content type to "application/xml", thanks! I said it was unable to submit a form in Mozilla, because 'document.submitForm' was undefined eventhough in the transformation output '<form name="submitForm" ...>" existed. Maybe XHTML does not support 'document.[form name]', dunno? Workaround suggested by Manos was to give my form an 'id="submitForm"' and use DOM to access it by "document.getElementById('submitForm')". This works. >David Regards, Daniel
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format