Passing arguments via header in php
Posted
by Prasoon Saurav
on Stack Overflow
See other posts from Stack Overflow
or by Prasoon Saurav
Published on 2010-05-21T07:45:04Z
Indexed on
2010/05/21
7:50 UTC
Read the original article
Hit count: 259
I have got 3 files with me.
login.html
login_check.php
welcome.php
In login.html
when the username and password is entered and submit button is clicked login_check.php
checks whether the username entry is in the database on the basis of $_POST['username']
and some SQL querry. Now I have put the following code at the bottom of login_check.php
login_check.php
header('Location:welcome.php')
But I want to pass $_POST['username'] from login_check.php
to welcome.php
so that I can make use of $_POST['username'] in my welcome page. Is there any way by which I can pass an argument like in the above case?
© Stack Overflow or respective owner