sungpeng Posted April 3, 2009 Share Posted April 3, 2009 <?php include ("".$_SERVER['DOCUMENT_ROOT']."/housing/includes/config.php"); $uid='sungpeng1'; $query = "SELECT * from users where loginname='$uid'"; while($resu=mysql_query($query)){ echo "$resu[llid]"; } ?> Hi I see nothing wrong with my script, but it give me an error FATAL ERROR maximum execution time is 30 seconds on line 6. Why is that so? Can anyone help? Link to comment https://forums.phpfreaks.com/topic/152340-solved-error-on-script/ Share on other sites More sharing options...
PFMaBiSmAd Posted April 3, 2009 Share Posted April 3, 2009 Because you are executing the mysql_query() in the while() loop. It is just executing the query over and over and over. You did read a basic php/mysql book before attempting this? Link to comment https://forums.phpfreaks.com/topic/152340-solved-error-on-script/#findComment-800068 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.