Jump to content

HELP ME PLEASE


georegjlee

Recommended Posts

I'm having trouble with this simple piece of code. I want to add a checkbox to the end of the table which I can do in html but when I try do it through PHP I get this error.

Parse error: parse error, unexpected T_STRING in C:\wamp\www\waterways1\admin\Problem_List.php on line 43

 

Here is a piece of the problem code.

 

<form id="form1" name="form1" method="post" action="">

<table border = "1" cellpadding = "3" cellspacing = "2">

 

<?php

 

for ( $counter = 0; $row = mysql_fetch_row($result); $counter++)

{

print( "<tr>");

 

foreach ( $row as $key => $value )

print ( "<td>$value</td>" );

print ( "<td>Check box to verify</td>");

print ( "<td><input type="checkbox" name="option1" value="Milk"></td>" );

 

print ( "</tr>" );

 

}

//close the connection

mysql_close($dbhandle);

?>

</table>

<input type="submit" value = "Update Problems" />

</form>

 

 

Link to comment
https://forums.phpfreaks.com/topic/41470-help-me-please/
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.