February 19th, 2010 by Lincoln Baxter III

Announcing – PrettyFaces 2.0.4: URL Rewriting for JSF 2.0

Add PrettyFaces to an existing JSF2 application less than 5 minutes:

  • Non-invasive! – never change your application internals, simply lay PrettyFaces on to an existing application.
  • Zero configuration* in a Servlet 3.0 environment – PrettyFaces core classes are automatically registered with the servlet container and JavaServer Faces. (No need to modify web.xml!)
  • Rapid development via automatic configuration reloading (when java.faces.PROJECT_STAGE = Development)
  • Custom Inbound/outbound URL rewriting rules – with built in support for canonicalization such as appending or removing trailing slashes, lowercasing, custom rewrites, and more.
  • Enhanced SEO and Rewriting support – including the ability to choose 301, 302, or internal redirects.
  • Outbound URL mapping rewriting – removes the need for <pretty:link> now <h:link> can be used to generate pretty, SEO-friendly URLs.
  • Named pattern / path-parameters – for integration with JSF2 and non-JSF applications – not all applications support EL, but they all understand ServletRequest.getParameter(…)

Maven Dependency

<dependency>
	<groupId>com.ocpsoft</groupId>
	<artifactId>ocpsoft-pretty-faces</artifactId>
	<version>2.0.4</version>
</dependency>

Posted in Releases

3 Comments

  1. Kris says:

    Hey great intro but Im getting a few problems…namely the exception below

    java.lang.ClassNotFoundException: com.ocpsoft.pretty.config.mapping.UrlMapping

    My setup is GlassFish v3 (build 74.2)
    My web app is JSF2.0, PrimeFaces 2.0.0 and Spring Security 3.

    Everything works fine until I add some mappings into the pretty-config.xml then it blows up.

    Ive tried moving the libs to be within glass fish and no joy there…

    Any idea hot to get around the problem?

    Cheers
    Kris

  2. Lincoln says:

    Hi Kris,

    I’m sorry to hear that you are having trouble 🙁

    Could you provide a sample project that reproduces the issue, and please attach it to the following issue [1]? We need more information.

    [1] http://code.google.com/p/prettyfaces/issues/detail?id=26

    Thanks,
    Lincoln

  3. Kris says:

    Hey Lincoln,

    Thanks for the quick reply Ive attached my sample app to the issue record. With any luck it should help as prettyfaces looks like exactly what Im after.

    Thanks,
    Kris

Leave a Comment




Please note: In order to submit code or special characters, wrap it in

[code lang="xml"][/code]
(for your language) - or your tags will be eaten.

Please note: Comment moderation is enabled and may delay your comment from appearing. There is no need to resubmit your comment.