Encoding JSF

0 respostas
R

Galera, fiz uma tela em JSF que da post para o servidor.

<?xml version='1.0' encoding='UTF-8' ?>  
<!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"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets">
<h:head>
	<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1" />

</h:head>
<h:body style="margin:0;position:relative;" scroll="yes">  
	<f:view> 
		<center><h:outputText value="introEe"  /></center><br/>
			    <h:form>  

								        <h:outputText value="login: " escape="false"/>
								        <h:inputText id="usuario"  required="true" label="login"  maxlength="20"/>
								       
								
								        <h:outputText value="senha: " escape="false"/>
								        <h:inputText id="senha"  required="true" label="senha" feedback="false" redisplay="true" maxlength="10"/> 
								       

											<h:panelGroup style="display:block; text-align:center">
							      				<h:commandButton value="entrar" icon="iconAccess" id="acessar" ajax="false"></h:commandButton>	
							    			</h:panelGroup>

											
				</h:form>	 

	</f:view>	
</h:body>
</html>

A questão é a acentuação que vai para o servidor só funciona se o encoding estiver da seguinte forma (ISO-8859-1):

Se eu colocar UTF-8, não funciona.

Me parece que o servidor sempre tenta converter para ISO. Não entendo o porque.

Abraços,

Criado 12 de março de 2012
Respostas 0
Participantes 1