in reply to Recalling the URL of initiating page

will say the referer was "www.mypage.com/page2.shtml" and NOT page1.shtml which it should!

I have used both the SSI and the exec cgi code and using HTTP_REFERER but it's absolutely not working. Can someone tell me how I can get the URL of the page that called it?

You should realize by now that this has everything to do with your webserver. So what you have to do is learn how your webserver works and figure out why HTTP_REFERER is not what you think it should be (this has nothing to do with perl).

Have you examined the rest of %ENV?

MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!"
I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README).
** The third rule of perl club is a statement of fact: pod is sexy.

  • Comment on Re: Recalling the URL of initiating page

Replies are listed 'Best First'.
Re^2: Recalling the URL of initiating page
by sulfericacid (Deacon) on Jan 24, 2005 at 16:46 UTC
    I did actually do a dumb on %ENV before posting this message but none of them had a solution that would work. (this is the full list of %ENV that printed out).
    SCRIPT_NAME /cgi-bin/server-test.pl SERVER_NAME www.mypage.com SERVER_ADMIN webmaster@mypage.com HTTP_ACCEPT_ENCODING gzip, deflate HTTP_CONNECTION Keep-Alive REQUEST_METHOD GET HTTP_ACCEPT image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, appli +cation/x-shockwave-flash, */* SCRIPT_FILENAME /home/spyders/public_html/cgi-bin/server-test.pl SERVER_SOFTWARE QUERY_STRING REMOTE_PORT 60118 HTTP_USER_AGENT Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NE +T CLR 1.1.4322) SERVER_PORT 80 HTTP_ACCEPT_LANGUAGE en-us REMOTE_ADDR 66.47.159.11 SERVER_PROTOCOL HTTP/1.1 PATH /usr/local/bin:/usr/bin:/bin REQUEST_URI /cgi-bin/server-test.pl GATEWAY_INTERFACE CGI/1.1 SERVER_ADDR 216.32.90.218 DOCUMENT_ROOT /home/spyders/public_html HTTP_HOST www.mypage.com
    As other people mentioned below, $ENV{REQUEST_URI} works just fine. It's weird I didn't get that in my dump though.

    Thanks for your help.



    "Age is nothing more than an inaccurate number bestowed upon us at birth as just another means for others to judge and classify us"

    sulfericacid