Execute function only when called by using header:location PHP
I'd like to be able to only execute a PHP function when I call it by using
header location.
function username() {
$_GET['username'];
}
and only run that function when I call it from a header as followed.
header('Location:www.domain.com/index.php?=getusername')
Once I type that in the URL then the function would execute, how do I
accomplish such use?
No comments:
Post a Comment