Vaadin7 url parameter cleanup

I have a Vaadin 7 app that has multiple request parameters in the incoming url request.


It is a 1 page app where view is composed of UI fragments
After I serve the request and naviagate to dosomething view fragment I 'd like to clean the url of token and view request parameters as it looks cluettered.

in other words I’d like to achieve something like this when vaadin returns the page to the user :


and not this :

Is that something possible ? If so how ?

Many thanks

Omer Berkman

Hi Omer,

One way to do this is to call Page.getCurrent().setLocation(“localhost:8080/prohire-maven/#!dosomething”)

Another way would be to give the token parameters as a parameter to you ‘dosomething’ view like localhost:8080/prohire-maven/#!dosomething/token/91b4f459. Then you could parse those parameters in your views enter()-method and do whatever you need to do with it. The good thing with this approach is that you are able to change the uri fragment (the part after #) as you want by using Page.getCurrent().setUriFragment(***, false) without causing page reload.

Hopefully this helps,