On Mon, 2004-02-09 at 19:22, Hugo Marcelino wrote: > Hi Users of cocoon: > > My name is Hugo Marcelino and a new problem came to me. > > Imagine this situation: > > -You want to define a link that has a reference like: > > <a href="caixão"> offcourse this is impossible to get but > if you encode your url you will get something like > > (1) <a href="caix%E3o"> wich is the same. Only this one is > encoded. >
Dear Hugo, First of all a quote from W3C: Although URIs do not contain non-ASCII values (see [URI], section 2.1) authors sometimes specify them in attribute values expecting URIs (i.e., defined with %URI; in the DTD). For instance, the following href value is illegal: <A href="http://foo.org/Håkon">...</A> We recommend that user agents adopt the following convention for handling non-ASCII characters in such cases: 1. Represent each character in UTF-8 (see [RFC2279]) as one or more bytes. 2. Escape these bytes with the URI escaping mechanism (i.e., by converting each byte to %HH, where HH is the hexadecimal notation of the byte value). This procedure results in a syntactically legal URI (as defined in [RFC1738], section 2.2 or [RFC2141], section 2) that is independent of the character encoding to which the HTML document carrying the URI may have been transcoded. > Now my problem is that this is not happening. What i'm getting is : > ( I use a simple xml and apply a xsltc transfomation.) > > .<a href="caião"> wich you can see is not the same as (1). > If you do an xslt transformation and add no <xsl:output encoding="ascii or iso-8859-1 or ...."/> to your stylesheet, your xml will be UTF-8 encoded after transformation.... Hope this helps Eduard > and as you can see the transformation was made incorrectly. > > After this i try to use the transformer type=encodeURL, after my > xsltc transformer, but the error was the same and the url had the sessionid > as was written in the documents. > And i was very careful in the encoding because i'm using ISO-8859-1 > everywere. > > Now my answer is: > > - Am i doing something wrong? Or this is something that we > can't do dynamically. > > I'm using Cocoon 2.1.3 and running under Jetty and i attached an > example in this mail. > > Thank you in Advance. <<test-iso.rar>> > > ______________________________________________________________________ > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] -- Eduard Drenth <[EMAIL PROTECTED]> home sweet home --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]