Jump to content

Select by count


Phpfr3ak

Recommended Posts

Hey, having an odd issue, looking to show players whos within 25 ranks of them lower and higher, i'm unsure as to why the following code doesn't actually do it... would anyone care to explain...

 

<?php
$score = $playerdata['score'];
$sql = "SELECT * FROM `players` WHERE '$score' BETWEEN 25 AND 75 ORDER BY `score` DESC";
$query = mysql_query($sql) or die(mysql_error());
$i=0;
while($players = mysql_fetch_array($query))
{
$i++;
?>

Link to comment
https://forums.phpfreaks.com/topic/255793-select-by-count/
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.