Answers for "php get the previous page url"

PHP
2

how to get previous page name in php

basename($_SERVER['HTTP_REFERER']);
Posted by: Guest on July-15-2020
0

how to get the previous page url in php

//This should be on the previous page
session_start();
$_SESSION["url"] = "the_url_of_page_we_want_to_get_back.php";

//This should be on the current executing page
session_start();
$previous_page_url = $_SESSION["url"];
Posted by: Guest on August-14-2021

Code answers related to "php get the previous page url"

Browse Popular Code Answers by Language