You have to use redirect rules on your web server, e.g. nginx, apache, 
tomcat, etc. That way you can deliver your app's index.html for different 
URLs based on regular expressions. Once your server delivers your index.html 
you can do Window.Location.getPath() in your EntryPoint and then do whatever 
you have to do.

The only downside is, that if your user names doesn't follow a specific 
pattern then you have to redirect nearly every request to your index.html 
(you would exclude your GWT-RPC/RequestFactory servlet URLs and in general 
all URLs that point to a file that really exists on your server). So you 
loose HTTP 404 errors on your web server because you can not decide if the 
request, that will point to a folder/file that does not exist on your 
server, e.g. /user123, is wrong and you should do a 404 or if its wrong but 
you have to redirect to index.html. If you want to keep 404's I think you 
have to change your desired URL to something like:
http://app.com/u/<username>. That way you could redirect only if you receive 
a request that starts with /u/.

A nice way to make your GWT pages bookmarkable is to use GWT's places 
framework. GWT Places uses the hash fragment of the URL to store information 
about the place (what place is active and what application state belongs to 
that place).

-- J.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-web-toolkit/-/7QUWpvMPDw8J.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to