Using anchor in urls

Splash Forums PrettyFaces Users Using anchor in urls

Tagged: 

This topic contains 1 reply, has 2 voices, and was last updated by  Lincoln Baxter III 1 year, 6 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #26857

    xavi
    Participant

    Hi,
    I need to use anchors # for urls but it seems that they get ingnored / not supported by pretty faces.

    I tried in 2 different ways, but none of them worked.

    1) Adding it

    <url-mapping id="home"> 
        <pattern value="/my-bookings" /> 
        <view-id value="/nick/index.xhtml#my-bookings" />
    </url-mapping> 

    2) In the java bean, setting the outcome to

    outcome="pretty:home#my-bookings";

    • This topic was modified 1 year, 6 months ago by  xavi.
    #26859

    The ‘#’ character denotes a purely client-side section of the URL, and will never be processed server-side, thus PrettyFaces never has an opportunity to operate on it.

    Check out this post – it might help give you some alternate ideas:
    http://stackoverflow.com/questions/3475076/retrieve-the-fragment-hash-from-a-url-and-inject-the-values-into-the-bean

    Sorry I cannot be of more help.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.

Comments are closed.