[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Accents problems in "action" attribute of a <fORM>

Subject: RE: Accents problems in "action" attribute of a <fORM> element
From: "Michael Kay" <mhk@xxxxxxxxx>
Date: Fri, 18 Jun 2004 12:26:58 +0100
javascript accent
XSLT 1.0 requires, for the HTML output methods, that URI-valued attributes
should be escaped using the %HH notation. "URI-valued" attributes here means
attributes defined in the HTML spec as taking a URI, which includes
form/@action. The reason for this is that the HTML spec requires such
escaping.

Unfortunately browsers don't always take kindly to the escaping, especially
when the URI is interpreted on the browser (e.g. a javascript URI, or the
fragment identifier of an ordinary a/@href. 

XSLT 2.0 allows you to suppress this escaping, and Saxon has an extension
attribute on xsl:output to prevent it with XSLT 1.0.

Michael Kay 

> -----Original Message-----
> From: Ricaud Matthieu [mailto:matthieu.ricaud@xxxxxxx] 
> Sent: 18 June 2004 11:11
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Subject:  Accents problems in "action" attribute of a 
> <fORM> element
> 
> Hi !
> 
> I'd like to work in english, so that i don't have accent 
> probems anymore !!
> 
> I'm working with MSXML parser and make the transfomation job 
> XML+XSL==>HTML
> with ASP/DOM
> 
> My XML starts with <?xml version="1.0" encoding="UTF-8"?>
> It contains an  <TRUC cible="ohe"> element.
> 
> While matching TRUC in an xsl template, i notice that accent problems
> depends on the HTML element in which I put the XML datas.
> If I do : <form action={@cible}> then I get after 
> transformation :  <form
> action="oh%C3%A9"/>
> If I do exactly the same but with another attribute name 
> (which is not HTML
> but anyway...) :
> <form actionABCD={@cible}> then I get after transformation :  <form
> action="ohe"/>
> 
> Is there some solutions, or something I missed ?
> 
> For information :
> 
> My XSL starts with  :
> <?xml version="1.0" encoding="UTF-8"?>
> <xsl:stylesheet version="1.0"
> xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
> <xsl:output method="html" encoding="ISO-8859-1"/>
> 
> (the problem is the same without the <xsl:output> element)
> 
> My ASP page makes the tranformation using Response.write
> objXML.transformNode(objXSL) (where objXML, and objXSL are 
> the loaded files
> of my xml and my xsl files)
> I put :
> Response.charset = "ISO-8859-1"
> Response.contentType = "text/html"
> at the beginning of the file but It doesn't seems to change anything.
> 
> 
> Hope you can help me, thanks in advance,
> 
> Matthieu.
> 
> 
> 
> 
> --+------------------------------------------------------------------
> XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
> To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
> or e-mail: <mailto:xsl-list-unsubscribe@xxxxxxxxxxxxxxxxxxxxxx>
> --+--
> 
> 


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.