Question

i am using prettyfaces 3.3.3, jsf 2.1 , primefaces 3.5 my question is that, is there any way to refresh url with out refreshing whole page like on ajax call

when i click on h:link see below code:

<!-- do not disturb with this #{subMenuBeanList.subMenuLinkBean}, this gives me pretty:anyMappingId-->
<h:link outcome="#{subMenuBeanList.subMenuLinkBean}" value="#{subMenuBeanList.subMenuNameBean}">
<f:param name="section" value="#{sectionBeanList.sectionNameBean}"/>
</h:link>

when i click on h:link, it gives me a page ( with this url localhost:8080/myApp/sectionname/anypattern) where i have a form with two input fields and one p:commandbutton here i submit the form using ajax call when it is submitted successfully i want url like this localhost:8080/myApp/sectionname/anypattern?f=2014-15 is this possible in prettyfaces?

Was it helpful?

Solution

To refresh the URL without doing a browser refresh, you will need to use something like HTML5 pushstate. You can use History.js for this: https://github.com/browserstate/history.js/#welcome-to-historyjs--v18b2-june-22-2013

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top