I am using java ee and request.getQueryString()
doesnt return the #hashpart
my/page?id=4#hash
I am using Struts 2
Is there any solution?
I am using java ee and request.getQueryString()
doesnt return the #hashpart
my/page?id=4#hash
I am using Struts 2
Is there any solution?
Not really. In many cases the hash tag isn't sent to the server by your client's browser.
For example, requesting this url:
http://stackoverflow.com/questions/2923610/java-getquerystring/2923618#2923618
Sends a request with these headers to the server:
GET /questions/2923610/java-getquerystring/2923618 HTTP/1.1
Host: stackoverflow.com
The hash part of the url is (in principle) useful only to the client side, so normally the browser does not send that portion to the server. Are you sure you are interested in reading it, in the server side? Normally, you shoudn't.
For special needs, you can read here http://stackoverflow.com/questions/317760/how-to-get-url-hash-from-server-side