I tried storing the REQUEST_URI in a session with the code below. I need to store the very first REQUEST_URI when a visitor lands on a page on our site and not have it overwritten when they begin browsing pages. This isn't working as I browse the site i'm seeing a new URI displayed by the echo.

session_start();
if ( !isset( $_SESSION['theuri'] ) ) {
    if ( !empty( $_SERVER['REQUEST_URI'] ) ) {
        $_SESSION['theuri'] = $_SERVER['REQUEST_URI'];
    }
}

echo $_SESSION['theuri'];



Question: What type of pen do I need for my rabbit?
Answer: Why not something like a baby play yard (also called baby fence or baby gate).



Some of them are expandable and have adjustable footprints.

 Images and links provided as examples. Not an endorsment of any goods or source.