Results 1 to 3 of 3
  1. #1
    dex3000 is offline Member
    Join Date
    Sep 2012
    Posts
    8
    Rep Power
    0

    Default JSF doesn't render right

    I have two types of .jsp files

    no1.jsp
    Java Code:
    <%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
    <%@ taglib prefix="f"  uri="http://java.sun.com/jsf/core"%>
    <%@ taglib prefix="h"  uri="http://java.sun.com/jsf/html"%>
    <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
    <title>Insert title here</title>
    </head>
    <body>
    <f:view>
    <h:outputText value="SUPER"></h:outputText>
          </f:view>
    </body>
    </html>
    no2.jsp
    Java Code:
    <?xml version="1.0" encoding="ISO-8859-1" ?>
    <%@ page language="java" contentType="text/html; charset=ISO-8859-1"
        pageEncoding="ISO-8859-1"%>
    <!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:f="http://java.sun.com/jsf/core" 
    xmlns:h="http://java.sun.com/jsf/html">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
    <title>Insert title here</title>
    </head>
    <body>
    <f:view>
    <h:outputText value="SUPER"></h:outputText>
    </f:view>
    </body>
    </html>
    problem is that no1.jsp renders right to html and it's all ok in browser.
    But no2.jsp doesn't, jsf tags f:view and h:outputText stays the same, they are not converted to true html.
    Why is that, this code is based on eclispe helios templates for jsf.
    I'm using Jboss 5.0 and jsf 1.2 Mojarra. Can somebody explain what is the problem. thx

  2. #2
    DarrylBurke's Avatar
    DarrylBurke is offline Forum Police
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,457
    Rep Power
    20

    Default Re: JSF doesn't render right

    Moved from New to Java

    db
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

  3. #3
    SpAm is offline Member
    Join Date
    Sep 2012
    Posts
    4
    Rep Power
    0

    Default Re: JSF doesn't render right

    Hi dex3000

    As far as I know, JSF uses UTF-8 by default, not ISO-8859-1

    I suggest changing all the ISO-8859-1 declarations (especially the XML one at the start) to UTF-8

Similar Threads

  1. Programatically call Render
    By joeyvitoro in forum Advanced Java
    Replies: 9
    Last Post: 11-22-2011, 05:11 PM
  2. Image Render Speed
    By zirbinator in forum Java 2D
    Replies: 2
    Last Post: 08-28-2011, 12:44 AM
  3. Render an image into a given quadrilateral
    By JeremyWilms in forum Java 2D
    Replies: 19
    Last Post: 08-24-2011, 08:26 AM
  4. Best Way To Render
    By rp181 in forum Java 2D
    Replies: 1
    Last Post: 03-24-2011, 07:20 PM
  5. Loki Render 0.3
    By levent in forum Java Software
    Replies: 0
    Last Post: 07-26-2007, 09:31 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •