3 Replies Latest reply on Oct 8, 2010 9:44 AM by ilya_shaikovsky

    How to use RichFaces in "normal" JSF

    ziyang

      I saw some samples on line. I got two ways to use RichFaces:

      1. Use in a JSP file. The initial portion of the JSP file is like this:

      <!doctype html public "-//w3c//dtd html 4.0 transitional//en">
      <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
      <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
      <!-- RichFaces tag library declaration -->
      <%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
      <%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>

       

      2. Use in a Facelets, a xhtml file. The initial portion of the xhtml file is like this:

      <?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:ui="http://java.sun.com/jsf/facelets"
            xmlns:f="http://java.sun.com/jsf/core"
            xmlns:h="http://java.sun.com/jsf/html"
            xmlns:a4j="http://richfaces.org/a4j"
           xmlns:rich="http://richfaces.org/rich" >

       

      I am currently working on a JSF projects. There are some XHTML files in the project. The initial part of the XHTML file is like this: 
      <!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">

      How could I use RichFaces in this project?
      Could you give me some samples of this kind?
      Thank you very much!!!!