Jump to content

[SOLVED] Syntax error


graham23s

Recommended Posts

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

<?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

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.