i have now got the following script to work
but when i try to print the $UserName to the web page (index.php) i get no output. What is the best way to keep the user name displayed through all the pages that they visit? 4 eg is it best to put the user name into a text file and get it from the file each time they open a new page. php does not seem to whant to hold this user name because when the page returns to index.php the $UserName will not print to the screen. am i going about this the wrong way? any thoughts on this would be helpful. thx
To err is human, to completely mess up takes a computer.
Code:
<?php
if(($_POST["UserName"]=="tony")&&($_POST["Password"]=="tony")) {
header("Location: index.php?UserName=$UserName");
} else {
header("Location: login.php?message=Invalid");
}
?>
To err is human, to completely mess up takes a computer.