vendredi 2 janvier 2015

illegal to have multiple occurrences of contentType with different values

illegal to have multiple occurrences of contentType with different values

Erreur dans la JSP:

détail de l'erreur:

Page directive: illegal to have multiple occurrences of contentType with different values

messages complets de l'erreur

janv. 16, 2015 10:56:59 AM org.apache.catalina.core.StandardWrapperValve invoke SEVERE: Servlet.service() for servlet [action] in context with path [] threw exception [/jsp/page.jsp (line: 49, column: 1) Page directive: illegal to have multiple occurrences of contentType with different values (old: text/html; charset=UTF-8, new: text/html; charset=ISO-8859-1)]
       at org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:42)
       


Solution:

dans la JSP des multiples balises sont contradictioires
<%@ page pageEncoding="UTF-8" %>
 
 <%@ page language="java"  charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>

UTF8 ou ISO-8859-1  ?
 
Il faut supprimer une de ces deux lignes

Aucun commentaire:

Enregistrer un commentaire