hi david... thanks for your response... I correct the value viewed into the final page... it is :

modalit&#224

I ignore encoding type but I presume to be the default because I didn't set it ..... this application uses myfaces + facelets.... you tell that decoding is job of facelets?

david delbecq ha scritto:
Luca Stancapiano a écrit :
hi.... I've seen that myfaces executes a strange encoding for characters. If I have something similar:

<h:form> <h:commandLink action="#{UserNumberBean.log}">
                      <h:outputText value="#{UserNumberBean.modalita}"/>
<f:param name="id" value="#{UserNumberBean.modalita}"/>
                   </h:commandLink>
 </h:form>


and UserNumberBean.modalita has 'modalità' as value, I see into the resulted page this value: modalit&#226 ,the ascii code instead of 'modalit&agrave' as well as for html pages. So when I click on the link, this value cannot to be decoded. I think about a bug of HTMLEncoder class... what do you think?
well, &#224 would be correct for an iso-8859-1 encoded response, but 226?? What the encoding used by myfaces in your case. is-8859, utf8? other? The component just use that encoding to convert characters to entities. Using &#....; notation is perfectly correct, event for links. If you have problems with it, it can also comes from the fact you form submit in an inappropriate encoding. use <h:form acceptcharset="...."> to specify expected encoding by server. Of course, you have to configure your server the same way. Here at work we force everything to utf-8.

Reply via email to