If i have an url like http://www.someurl.com/index.jsp#someAnchor
can and how can i get the value of the anchor???
| SitePoint Sponsor |
If i have an url like http://www.someurl.com/index.jsp#someAnchor
can and how can i get the value of the anchor???





use request.getQueryString() and then parse out everything after the #, there are several ways to do this. One easy way:
Code:String query = request.getQueryString(); int index = query.lastIndexOf('#'); String anchor = query.substring(index);
Well this is not working... i read about this and it can't be done beacause anchors are not sent to the server, just url and query string are send... anyway thanks for the help rozner
Bookmarks