I am using this to get my current url.
https://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]
But it is not returning character after #. I have my url like this
https://example.com/category/post/#loc
and with this code i am getting only
https://example.com/category/post/
How i can get a complete url?