Awesomexr
New Member
- Messages
- 118
- Reaction score
- 4
- Points
- 0
		Code:
	
	Warning:  mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/haslamx/public_html/vote/src/index.php on line 115Here is line 115 of index.php:
		Code:
	
	<?php
/**
Display the results from the database
**/
$q = "SELECT * FROM entries";
$r = mysql_query($q);
>> Line 115 :if(mysql_num_rows($r)>0): //table is non-empty
    while($row = mysql_fetch_assoc($r)):
        $net_vote = $row['votes_up'] - $row['votes_down']; //this is the net result of voting up and voting down
?>Can anyone tell me what I'm doing wrong? Help would be greatly appreciated, thank you!
 
				 
 
		