Re: Check Boxes!
| From: | p.whiter | Date: | Sat, 20 Oct 2001 09:14:11 +0000 |
| Subject: | Re: Check Boxes! | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-13557@lists.php.net to get a copy of this message | ||
Try removing the parenthesis from your update sql query........
$sql = "UPDATE vacancies SET AuthStatus='1' WHERE JobID = '$JobID'";
HTH
Paul
----- Original Message -----
From: "Matt C" <matthewcothier@hotmail.com>
To: <php-db@lists.php.net>
Sent: Saturday, October 20, 2001 12:43 AM
Subject: [PHP-DB] Check Boxes!
: I still can't get my damn code working :( :( :(
:
: All I want to do is have any records with a checked check box given the
: value of 1 in the AuthStatus row.
:
: Can anyone help me please?
:
: -----
:
:
: <?php
:
: if ($submit) {
:
: //Get the DB result
: $dbResult = mysql_query("SELECT * FROM vacancies WHERE (AuthStatus = '0')
: ORDER BY JobID DESC LIMIT 1");
:
: $oRow = mysql_fetch_object($dbResult);
:
: $Max_JobID = $oRow->JobID;
:
: for ($i = 0; $i <= $Max_JobID; $i++) {
: if($HTTP_POST_VARS["chkAuthStatus_$i"] = 'on') {
: $JobID = $i;
: }
:
: if($JobID){
:
: $sql = "UPDATE vacancies SET AuthStatus='1' WHERE (JobID =
'$JobID')";
: mysql_query($sql,$dbconnect);
:
: }
:
:
: }
: }
:
: ?>
:
: _________________________________________________________________
: Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp
:
:
: --
: PHP Database Mailing List (http://www.php.net/)
: To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net
: For additional commands, e-mail: php-db-help@lists.php.net
: To contact the list administrators, e-mail: php-list-admin@lists.php.net
: