php-db | 2000121

Re: [PHP-DB] PHP/postgres form INSERT question From: Alexey Borzov (borz_off <email protected>)
Date: 12/07/00

Greetings, John!

At 07.12.2000, 12:12, you wrote:
JS> I'm working on a software survey and have 30 categories that will be voted
JS> on. I've set it up so each cat is it's own table with only two fields, app
JS> and rank. Also there is to be one submit button which will post all the
JS> variables. Is there a way to for loop through the vars. Or an
JS> if(there_is_a_variable()) statement.

You can loop:

while (list($appname, $rank) = each($HTTP_POST_VARS)) {
    // do your DB stuff here
}

Or you can check:
if (!empty($that_particular_appname)) {
    // do your DB stuff here
}

-- 
Yours, Alexey V. Borzov, Webmaster of RDW

-- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-db-unsubscribe <email protected> For additional commands, e-mail: php-db-help <email protected> To contact the list administrators, e-mail: php-list-admin <email protected>