in reply to Get anchors from CGI?

You cannot access the #anchor part. If you look at the BNF in RFC 1738, you'll see that it's not part of a URL. When a browser encounters a link of the form:
http://www.example.com/some/path/down/here?arguments#anchor
it will connect to www.example.com and issue a request for /some/path/down/here?arguments. In that reply, it will look for an anchor named anchor. But this is never send to the server, so the CGI does not have to bother with it.

Abigail