hi,
the FormEncoding parameter was renamed to _charset_  (see [0]):

so:
<input name="_charset_" type="hidden" value="UTF-8"/>

should do the trick.
regards, toby

[0] https://issues.apache.org/jira/browse/SLING-298

On 8/19/08, Juerg Meier <[EMAIL PROTECTED]> wrote:
> Hi all,
>
>  This problem is driving me nuts...
>
>  I don't get UTF-8 Umlaute correctly into the JCR. I double-checked
>  everything to ensure the page is *really* UTF-8, and lately I discovered
>  the thing with the hidden "FormEncoding" parameter. But instead of
>  getting a clean 'ü', I still get something like "ü" (two byte UFT-8),
>  and additionally a string property named "FormEncoding" on that node...
>
>
>  Here's the JSP:
>
>  <?xml version="1.0" encoding="UTF-8" ?>
>  <%@ page language="java" contentType="text/html; charset=UTF-8"
>     pageEncoding="UTF-8"%>
>  <[EMAIL PROTECTED] import="javax.jcr.query.*, javax.jcr.*,
>  org.apache.sling.api.resource.Resource"%>
>  <[EMAIL PROTECTED] session="false"%>
>  <[EMAIL PROTECTED] prefix="sling"
>  uri="http://sling.apache.org/taglibs/sling/1.0"%>
>  <sling:defineObjects/>
>
>
>  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
>  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";>
>  <html xmlns="http://www.w3.org/1999/xhtml";>
>  <head>
>  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
>  <title>Insert title here</title>
>  </head>
>  <body>
>
>         <form name="form1" method="post" action="<%= currentNode.getPath()%>"
>  >
>         <table width="80%" border="0" cellspacing="4" cellpadding="4">
>         <tr>
>                 <td>Titel:</td>
>                 <td><input name="title" type="text" id="title" size="80"
>  maxlength="128" value="<%= currentNode.getProperty("title").getString()
>  %>"></td>
>         </tr>
>
>         <tr>
>                 <td><input name="FormEncoding" type="hidden" value="UTF-8"/> 
> </td>
>                 <td><input type="submit" value="Ändern"></td>
>         </tr>
>         </table>
>         </form>
>
>  </body>
>  </html>
>
>
>  Here what the browser sends:
>   POSTDATA=title=Hilfe+bei+Wetterf%C3%BChligkeit&FormEncoding=UTF-8
>
>
>  Any help is highly appreciated!
>
>  Regards,
>
> Juerg
>
>
>
>
>

Reply via email to