Webpage response to selection & $_POST

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all.

I have a list of users in a database that I would like to show on a dynamic webpage. With each of these users that shows up on the page, there is going to be a checkbox next to their name so that I can perform multiple tasks, such as 'Remove User' or 'Modify Information'. I have all of the appropriate information showing up on the page, including the checkboxes.

My question is... if I select a checkbox for a user, the other pages do not even recognize that I have selected that checkbox and I am using the $_POST method - why is that? I have even attempted to use the import_request_variables function - no luck. So, I cannot verify which users I want to perform an action on.

Anyone have any ideas? Snippets of code to follow...

Thanks in advance,
~Philip


<form action="performaction.php" method="post">
<table>
<?php
for ($j=0; $j<$numRows; $j++) {
echo '<tr>' . "\n";
echo ' <td><input type="checkbox" name="user' . $j . '" value="1"></td>' . "\n";
echo ' <td>' . $dbid[$j] . '</td>' . "\n";
echo ' <td>' . $firstName[$j] . '</td>' . "\n";
echo ' <td>' . $lastName[$j] . '</td>' . "\n";
echo ' <td>' . $uid[$j] . '</td>' . "\n";
echo ' <td>' . $username[$j] . '</td>' . "\n";
echo ' <td>' . $classification[$j] . '</td>' . "\n";
echo ' </tr>' . "\n";
}
?>
</table>


<input type="submit" name="removeuser" value="Remove User" />
<input type="submit" name="modifyclass" value="Modify Classification" />
<input type="hidden" name="beenSubmitted" value="1" />
</form>

[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux