Jump to content

[SOLVED] logic help


lc21

Recommended Posts

I am developing a log for problems recorded with a system and I have these problems being output to a table within a form and each record has a radio button for the user to select.

 

they are being output as in the code below:

 

<?php
while($display=mysql_fetch_array($query))
{
     echo "<tr><td>".$display['problemId']."</td><td>".$display['name']."</td></tr>";
}
?>

 

How do I get the unique identifer (problemId) to be chosen when the user selects the appropreate radio button? as problems can be added and removed all the time.

 

Thanks.

Link to comment
https://forums.phpfreaks.com/topic/60019-solved-logic-help/
Share on other sites

<form method="post" action="<?php $_SERVER['PHP_SELF']; ?>">

 

<?php

while($display=mysql_fetch_array($query))

{

    echo "<tr><td>".$display['problemId']."</td><td>".$display['name']."</td>

              <td><input type=\"radio\" name=\"problemId\" value=\"$display\"></td></tr>";

}

?>

<tr>

  <td>

    <input type="submit" value="Submit">

    < /form>

  </td>

</tr>

Link to comment
https://forums.phpfreaks.com/topic/60019-solved-logic-help/#findComment-298568
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.