0

I know I can use the <f:viewParam> tag to set GET request parameters in a managed bean. This works great when passing URL as:

mysite.com/products.xhtml?catId=growing-systems

But is there another mechanism to process URI addresses such as:

mysite.com/products.html#/growing-systems -OR-
mysite.com/products.html#/growing-systems/garden-tower-3370084_01

Where the search strings (parameters for all intents and purposes) are separated by dashes.

Thanks a lot in advance!!!

SergioBrito
  • 73
  • 1
  • 9
  • Those aren't URL parameters, so you can't receive them as URL parameters. URL parameters are name-value pairs. – user207421 Nov 02 '14 at 00:50
  • Dashes ("-") or *slashes* ("/")? [PrettyFaces](http://ocpsoft.org/prettyfaces/) handles your apparent need precisely – kolossus Nov 03 '14 at 00:33
  • Thanks to all for the replies. @kolossus, PrettyFaces looks awesome! It is exactly what I was looking for. I couldn't accept as answer because this tip was given as a comment. Everyone else looking for this solution, this is the answer. Check out this comment explaining a basic configuration: `` – SergioBrito Nov 03 '14 at 16:31

1 Answers1

0

The anchor part of the URL is intercepted by the browser, and is not part of the URL POST/GET request back to the server. You might be able to locally process the URI with anchor within the browser using javascript. See previous answer 1 and previous answer 2

Community
  • 1
  • 1
YoYo
  • 9,157
  • 8
  • 57
  • 74