Find jobs - Debt Consolidation - Debt Consolidation - Find jobs - Kamala Harris

PDA

View Full Version : help in php.


cris02
Apr 25th 2008, 10:22 pm
hi i have a code here:

<?php
$query2 = "SELECT * FROM gold where reward_type='gold miles'";
$result2 = mysql_query($query2);
$counter = 0;
while($info = mysql_fetch_array($result2)) {
print "<table width='98%' border='1' align='center' cellpadding='0' cellspacing='0' bordercolor='#CCCCCC'>
<tr>
<td width=6%><input type='checkbox' name='checkbox".$info['rid']."' value=".$info['F3']."><input type='hidden' name=".$info['F3']." id='hide' value=".$info['F3']."></td>
<td width=13%>".$info['F3']."</td>
<td width=49%>".$info['p_name']."</td>
<td width=8%>".$info['F6']."</td>
<td width=8%>".$info['F7']."</td>
<td width=8%>".$info['F8']."</td>
<td width=8%>".$info['F9']."</td>
</tr>
</table>";
}
?>

which is loop on every record. now i want to display all the value of each checkboxes that i've checked on other page by submitting the form. in short i want to detect this name='checkbox".$info['rid']."' on the other page, which is ".$info['rid']." is a autonumber came from databse. anyone can help,, thanks in advance.

kmap
Apr 26th 2008, 9:49 am
Did u made a form?

if yes then


<?php $query2 = "SELECT * FROM gold where reward_type='gold miles'"; $result2 = mysql_query($query2); $counter = 0; while($info = mysql_fetch_array($result2)) { print "<table width='98%' border='1' align='center' cellpadding='0' cellspacing='0' bordercolor='#CCCCCC'> <tr> <td width=6%>".$_POST['checkbox'.$info['rid']]."</td></table>";

?>