Jump to content

storing a field in a loop


patelp7

Recommended Posts

I am trying to store the "subject" that the user selects and output the specific deatils of the subject on viewspecificbull.php.

 

But it is only storing the last subject.  How do make it store the selected subject and not the last subject?

 

while ($numofsubs = mysql_fetch_array($result))

{

 

//echo <td align="left"><a href="viewspecificbull.php?id=' . $numofsubs['Subject'] . '">View</td></br>

echo ('<td align="left">' . $numofsubs['Subject'] . '</td>

<td align=left><a href="viewspecificbull.php?id=' . $numofsubs['Subject'] . '">View Subject: </a></td></br>');

 

$_SESSION['Subject']= $numofsubs['Subject'];

 

 

}

Link to comment
https://forums.phpfreaks.com/topic/42025-storing-a-field-in-a-loop/
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.