Querying something off the last page

Discussion in 'Programming' started by almondj, May 13, 2008.

  1. #1
    I'm not sure if this would be PHP or JavaScript. But what I want is a script that queries the last pages title. Say once a transaction is complete on PayPal they are then forwarded to my success.php page and on it I will have text and I want it to contain the title of the PayPal completion page.
     
    almondj, May 13, 2008 IP
  2. chantown

    chantown Peon

    Messages:
    406
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #2
    PHP LIMIT in mysql?
     
    chantown, May 13, 2008 IP
  3. WhaLberg

    WhaLberg Peon

    Messages:
    44
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    You can keep the record of it in $_SESSION.

    You need to add that to every single page.
    $_SESSION['lastpage'] = "Last Page Title";
    PHP:
    And then you can display like that:
    echo "You were previously reading our " . $_SESSION['lastpage'] . " page.";
    PHP:
     
    WhaLberg, May 14, 2008 IP
  4. almondj

    almondj Peon

    Messages:
    768
    Likes Received:
    11
    Best Answers:
    1
    Trophy Points:
    0
    #4
    Thanks :). I did it here, but it just says this: You were previously reading our Last Page Title page.
     
    almondj, May 19, 2008 IP
  5. WhaLberg

    WhaLberg Peon

    Messages:
    44
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    I guess I didn't explain in a good way.

    You need to put the code $_SESSION['lastpage'] = "Last Page Title"; to all of your pages with your own page title so you need to change the "Last Page Title" to whatever your page title is.
     
    WhaLberg, May 22, 2008 IP