westmatrix99
03-15-2007, 12:12 PM
Please tell what I am doing wrong?
I am using this form to post this page back to itself to unsubscribe users by changing a value from "Y" to "N" based on the email address posted.
<form action="<?php $_SERVER['PHP_SELF']; ?>" method="get" name="modeloform">
<table width="100%" border="0" cellpadding="2" cellspacing="0" class="table1">
<tr><td width="9%" valign="top" class="normaltext">Email:</td>
<td width="32%" valign="top"><input name="email" type="text" size="32"></td>
<td width="59%" valign="top" class="normaltext">Required field.</td>
</tr><tr><td>
<input name="active" type="hidden" id="active" value="N" size="1" checked>
<input name="StuID" type="hidden" id="StuID" value="<?php echo $_GET['id']; ?>" size="1" checked></td>
<td colspan=2>
<input type="submit" value="Submit" ></td></tr></table>
</form>
I get errors, when I post this below any idea why?
<?php
$unsub = $_POST['active']
$mail = $_POST['email']
?>
This is the error:
Parse error: parse error, unexpected T_VARIABLE in c:\Inetpub\wwwroot\stu2stuphp\unsubscribe2.php on line 4
On line 4:
$mail = $_POST['email']
Cheers
West
I am using this form to post this page back to itself to unsubscribe users by changing a value from "Y" to "N" based on the email address posted.
<form action="<?php $_SERVER['PHP_SELF']; ?>" method="get" name="modeloform">
<table width="100%" border="0" cellpadding="2" cellspacing="0" class="table1">
<tr><td width="9%" valign="top" class="normaltext">Email:</td>
<td width="32%" valign="top"><input name="email" type="text" size="32"></td>
<td width="59%" valign="top" class="normaltext">Required field.</td>
</tr><tr><td>
<input name="active" type="hidden" id="active" value="N" size="1" checked>
<input name="StuID" type="hidden" id="StuID" value="<?php echo $_GET['id']; ?>" size="1" checked></td>
<td colspan=2>
<input type="submit" value="Submit" ></td></tr></table>
</form>
I get errors, when I post this below any idea why?
<?php
$unsub = $_POST['active']
$mail = $_POST['email']
?>
This is the error:
Parse error: parse error, unexpected T_VARIABLE in c:\Inetpub\wwwroot\stu2stuphp\unsubscribe2.php on line 4
On line 4:
$mail = $_POST['email']
Cheers
West