Use facelets, it will save you lot of pain. I have never been a JSP
fan (we now use Velocity when we need a templating language).Choosing
it as your template language in a JSF application is a great way to
torture your developers. Also facelets give you a free templating
engine à la Tiles out of the box.
On 7/26/06, Mike Kienenberger <[EMAIL PROTECTED]> wrote:
On 7/26/06, Colin Chalmers <[EMAIL PROTECTED]> wrote:
> Should we decide to migrate an older project to facelets is it possible
> to use the two view technologies side-by-side so we could migrate page
> by page?
Define your JSP suffix and your facelets suffix:
<context-param>
<param-name>javax.faces.DEFAULT_SUFFIX</param-name>
<param-value>.jspx</param-value>
</context-param>
<context-param>
<param-name>facelets.VIEW_MAPPINGS</param-name>
<param-value>*.xhtml</param-value>
</context-param>
and then use prefix-mapping:
<servlet-mapping>
<servlet-name>FacesServlet</servlet-name>
<url-pattern>/faces/*</url-pattern>
</servlet-mapping>
At this point, you can use both jsp and facelets (You'll find life
easier if you migrate your .jsp files to .jspx first -- .jspx to
.xhtml is trivial).
http://localhost:8080/faces/pages/Edit.xhtml -- facelets url
http://localhost:8080/faces/pages/Edit.jspx -- jspx url