graham23s Posted June 30, 2007 Share Posted June 30, 2007 Hi Guys, in this piece of code: // Figure out the total number of results in DB: $total_results = mysql_result(mysql_query("SELECT COUNT(*) as Num FROM `uploaded_files`"; if($category_id > 0) { echo $total_results .= " WHERE `cat_id`='$cat_id'"),0); } i'm getting: syntax error, unexpected ';' can anyone tell me what i need to do to fix this? thanks guys Graham Link to comment https://forums.phpfreaks.com/topic/57861-solved-syntax-error/ Share on other sites More sharing options...
pocobueno1388 Posted June 30, 2007 Share Posted June 30, 2007 <?php // Figure out the total number of results in DB: $total_results = mysql_result(mysql_query("SELECT COUNT(*) as Num FROM `uploaded_files`")); if($category_id > 0) { echo $total_results .= " WHERE `cat_id`='$cat_id'\"),0)"; } ?> Link to comment https://forums.phpfreaks.com/topic/57861-solved-syntax-error/#findComment-286711 Share on other sites More sharing options...
graham23s Posted June 30, 2007 Author Share Posted June 30, 2007 Thanks pocu:) Graham Link to comment https://forums.phpfreaks.com/topic/57861-solved-syntax-error/#findComment-286713 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.