Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

jsf page character encoding error from managed bean

santiago_ncOct 2 2014 — edited Oct 2 2014

My application is internationalized then I need special characters (accents from spanish, copyright symbol, ...). I have test that If I get the string from a managed bean this doesn't works.

JSF Page:

<?xml version='1.0' encoding='UTF-8'?>

<!DOCTYPE html>

<f:view xmlns:f="http://java.sun.com/jsf/core" xmlns:af="http://xmlns.oracle.com/adf/faces/rich">

    <af:document title="Test" id="d1">       

        <af:form id="f1">       

          <af:panelGroupLayout id="pgl1">

            <af:outputText id="ot1" value="áéióúñ © it works" />

            <af:outputText id="ot2" value="#{myBean.text} it doesn't work" />

          </af:panelGroupLayout>

        </af:form>

    </af:document>

</f:view>

Bean

public Class MyBean {

  public MyBean() {

  }

 

  public String getText(){

    return "áéióúñ ©";

  }

}

I have found this old post:

utf-8 problem with ADF

But this solution is for JSPX pages:

<jsp:directive.page contentType="text/html;charset=UTF-8"/>

How can I solve this issue for ADF 12c + JSF pages/ JSF Page Fragments.?

This post has been answered by kdario on Oct 2 2014
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 30 2014
Added on Oct 2 2014
2 comments
1,245 views