Error with mysql_query

I am getting the error below, every time I run my script, not sure what Im doing wrong:

Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in /home/webcow/public_html/futurepon/vote/index.php on line 47

same for line 48, 51, 52, 55, 56

—MY SCRIPT—index.php

<?php
include(“dbcon.php”);

$query=“select up_rated as up_rated from dzone_rating”;
$result=mysql_query($dbc,$query);
$row=mysql_fetch_array($result);

$query2=“select down_rated as down_rated from dzone_rating”;
$result2=mysql_query($dbc,$query2);
$row2=mysql_fetch_array($result2);

$query3=“select rating as rating from digg_rating”;
$result3=mysql_query($dbc,$query3);
$row3=mysql_fetch_array($result3);

?>

—MY SCRIPT—dbcon.php

<?php

$dbc=mysqli_connect(‘localhost’,‘user_alien’,‘alien123’,‘futurepon’);

?>

You’re using mysqli to connect and mysql to make queries. That doesn’t work. Either stick to mysqli or mysql, but don’t mix and mach.

Also, for mysql and mysqli the argument order is different:

mysqli_query($conn, $query);
mysql_query($query, $conn);

:slight_smile: