Okey dokey, I don't have msaccess here (check
http://uk.php.net/odbc_connect for odbc stuff)
This is the would do the same thing if you were connecting to a mysql database:
<?php
// stuff we need from the request
$txtuser = $_REQUEST['txtuser'] ;
$txtpword = $_REQUEST['txtpword'];
// set up our db connection
$db = mysql_connect("localhost", "username", "password");
mysql_select_db("database_name",$db) || die("Problem connecting to database");
// get our SQL ready
$sql = "SELECT * FROM ADMIN WHERE ";
$sql .= "username='$txtuser' AND password='$txtpword'";
// run the query
$results = mysql_query($sql);
// do stuff according to what cam back
if (mysql_num_rows($results)==1 && $results)
login_action();
else
auth_error();
?>
Cheers
Charlie
--
Don't Stand on your head - you'll get footprints in your hair
http://charlieharvey.org.uk
http://charlieharvey.com