SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Enthusiast
    Join Date
    Jul 2000
    Location
    Outside Providence
    Posts
    88
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm trying to figure out which page I came from so that I can go back there. I know this is elementary and if I was doing it in another language I'd be fine, but PHP is giving me some problems (it's new for me). I'm using $HTTP_REFERER trying to store the value and it's not working. Is there another variable that I can refer to?

    I'm using:

    $GoBackTo = $HTTP_REFERER

    I would normally do a response.redirect (in ASP) to go to the page, how do I do it in PHP?

    Thanks for your help.

    April
    TEAMWORK is the fuel that allows common people
    to produce uncommon results.

  2. #2
    SitePoint Wizard
    Join Date
    Apr 2000
    Posts
    1,483
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally posted by acox


    I would normally do a response.redirect (in ASP) to go to the page, how do I do it in PHP?

    Thanks for your help.

    April
    I'm not sure about your first problem, but to do a redirect try this:
    Code:
    $url = "http://www.sitepoint.com";
    header("Location: $url");

  3. #3
    SitePoint Addict kunal's Avatar
    Join Date
    Oct 2000
    Posts
    307
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    $url = getenv(HTTP_REFERER);
    i dunno...


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •