The idea/goal:
I have a username and password inside a text file on my computer. The form on the index page allows the user to sign in with their us
You can start a session and put the form values into the $_SESSION variable, which will be available on all pages.
// On the page where your form is submitted:
session_start();
$_SESSION['name'] = $_POST['name'];
// On the page where the user is redirected:
session_start();
echo $_SESSION['name'];
Note that in reality you would probably want to include some form validation too!