How to get the current URL when using a Reverse Proxy?

How to get the current URL when using a Reverse Proxy?

  

Hi everyone.

I am testing my webpage with the URL https://xxx.xxx.x.x/eSpaceName/ etc etc, where the set ofX's represent my Reverse Proxy IP.


 In the screen, I use GetBookmarkableURL() in a expression to print the current URL and I get a different IP!?? Instead of the Reverse Proxy IP, It is printed the environment IP :\

This is causing me a lot of troubles, specially when I want to open popups that are being referenced in other eSpaces or when I use the ExternalSite navigator to go to a certain page: it won't open and I receive the message "Page not found".


Two questions:

1) Why does this happen? Something wrong with my configurations?
2) How can I get the exact address which is written in my address bar?

Thank you for your help!