balkan7 Posted October 28, 2006 Share Posted October 28, 2006 Warning: Wrong parameter count for mysql_query() [code]$query = mysql_query ($dbname,"select * from top_cats order by catname",$db) or die (mysql_error());[/code] Quote Link to comment https://forums.phpfreaks.com/topic/25394-mysql-query-error/ Share on other sites More sharing options...
gmwebs Posted October 28, 2006 Share Posted October 28, 2006 You are not using it correctly. Refer to the [url=http://uk.php.net/mysql_query]documentation[/url] on how to correctly use it. Quote Link to comment https://forums.phpfreaks.com/topic/25394-mysql-query-error/#findComment-115810 Share on other sites More sharing options...
wildteen88 Posted October 28, 2006 Share Posted October 28, 2006 Mysql query only has two parameters. Your code code has three parameters. The only parameters mysql_query has is the query and the secound parameter which is optional is the link identify to the mysql connection. So this is what the line should look like:[code]$query = mysql_query ("select * from top_cats order by catname") or die (mysql_error());[/code] Quote Link to comment https://forums.phpfreaks.com/topic/25394-mysql-query-error/#findComment-115811 Share on other sites More sharing options...
balkan7 Posted October 28, 2006 Author Share Posted October 28, 2006 thank you, i was try whit include datebase but show me error, i fix now, thanks again. Quote Link to comment https://forums.phpfreaks.com/topic/25394-mysql-query-error/#findComment-115813 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.