The redirection is simple (take care to use it before output something)
PHP Code:
header( "Location: login_form.html" );
To use the name and password at same time it is simple too, you can do a select query like :
SELECT name, password FROM the_table WHERE name='username' AND password='pass'
If it returns a row, log is ok