how to route by anchor?

I'm new to here.I have a problem about routing anchor or redirect url
by anchors,for example:
I want to request a url like "" and then
response a new url like "". My problem is I
don't know how to read the anchor from a request.
Any thought? thanks in advance :slight_smile:

Unfortunately, you can't. Anchors are not passed to the server in the
request. The only way to do anything with them is to read them on the
client side with JavaScript, and pass information about them to the

See this article for an example of how they're used to maintain
browser history:

thanks for your answer, now I got it.