jeff5656 Posted December 17, 2008 Share Posted December 17, 2008 I get Parse error: syntax error, unexpected $end in C:\wamp\www\warren\billing\editdos.php on line 210 Did I not include a bracket or somehting? I can't figure out why this doesn't work. <td> <?php $query2 = "SELECT * FROM proc_list"; $results2 = mysql_query ($query2) or die (mysql_error()); ?> <select name = "procedure" > <option selected="">Select Procedure <?php while ($row2 = mysql_fetch_assoc ($results2)) { ?><option value = "<?php echo $row2['procedures'];?>"><?php echo $row2['procedures'];?> } </select> </td></tr> Quote Link to comment https://forums.phpfreaks.com/topic/137384-solved-unexpected-end/ Share on other sites More sharing options...
trq Posted December 17, 2008 Share Posted December 17, 2008 You have brace just after this line... ?><option value = "<?php echo $row2['procedures'];?>"><?php echo $row2['procedures'];?> It doesn't appear to be within php though so shouldn't generate a parse error. Quote Link to comment https://forums.phpfreaks.com/topic/137384-solved-unexpected-end/#findComment-717843 Share on other sites More sharing options...
Maq Posted December 17, 2008 Share Posted December 17, 2008 Shouldn't you close your option tags? Quote Link to comment https://forums.phpfreaks.com/topic/137384-solved-unexpected-end/#findComment-717846 Share on other sites More sharing options...
jeff5656 Posted December 17, 2008 Author Share Posted December 17, 2008 ou have brace just after this line... Oops your right thanks! Shouldn't you close your option tags? </option> I never have and it seems to work. Otherwise I have to write </option> over and over Quote Link to comment https://forums.phpfreaks.com/topic/137384-solved-unexpected-end/#findComment-717847 Share on other sites More sharing options...
Lamez Posted December 17, 2008 Share Posted December 17, 2008 ou have brace just after this line... Oops your right thanks! Shouldn't you close your option tags? </option> I never have and it seems to work. Otherwise I have to write </option> over and over Its good programming habits. You always close an open tag. Its like leaving your front door open, once you are in then you close the door. So close your tags! Quote Link to comment https://forums.phpfreaks.com/topic/137384-solved-unexpected-end/#findComment-717857 Share on other sites More sharing options...
Maq Posted December 17, 2008 Share Posted December 17, 2008 ou have brace just after this line... Oops your right thanks! Shouldn't you close your option tags? I never have and it seems to work. Otherwise I have to write over and over It may not be the cause of the error but, like Lamez said, it's good programming practice. I don't think it will validate either. Quote Link to comment https://forums.phpfreaks.com/topic/137384-solved-unexpected-end/#findComment-717866 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.