[Help] Проблем с ранкинга в сайта

DarkEvil

Active Member
Joined
Jan 29, 2011
Messages
516
Reaction score
106
Здравейте.

Проблема ми е следния:

След като цъкна на "Ranking" и въпреки, че имам хора в сървъра които играят, не ми излиза никой. Същото се получава и когато гледам класовете по отделно, излизат единствено баннатите и онлайн играчите.

Някой знае ли как да го оправя.

Сайта ми: КЛИК ТУК!
 
ще прикачиш ли папката ранкинг тук?
 
ще прикачиш ли папката ранкинг тук?

Ето я, но силно се чудя дали е от нея, понеже и друг път съм пускал 97d+99i с нея. Все пак ако се получи, ще съм ти благодарен. М/у другото не ми работеше и на "BattleZone от Damian".

Благодаря предварително!
 

Attachments

  • rankings.rar
    44.4 KB · Views: 6
  • config.rar
    267 bytes · Views: 3
Ето я, но силно се чудя дали е от нея, понеже и друг път съм пускал 97d+99i с нея. Все пак ако се получи, ще съм ти благодарен. М/у другото не ми работеше и на "BattleZone от Damian".

Благодаря предварително!

Я прикачи и includes/muweb.php ама може и да не помогне ако резолтатите са от базата данни който извлича.
 
защо първо не инсталираш тоя му уеб може да е от това ?
 
  • Like
Reactions: A.ssassi.N
Пробвай така:

Code:
<?
require("config/config.php");

$query = "Select TOP 50 Name,Class,cLevel,resets,Money,PKcount,Strength,Dexterity,Vitality,Energy from Character where ctlcode !='32' and ctlcode !='8' order by resets desc ,clevel desc";

$result = $db->Execute($query);

$content ='<br><font face=Tahoma size=2><center><b>Top 50 Players</b></center></font>
<br></br>
<font color=white>
<center><table  height=0 cellspacing=1 cellpadding=1 width=480 border=0 bordercolor=DarkGray><tr> 
<td bordercolor=DarkGray width=10 height=20 valign=top align=center><font color=black face=Tahoma><b><u>ID</font></td>
<td bordercolor=DarkGray width=110 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Name</font></b></td>
<td bordercolor=DarkGray width=30 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Level</font></b></td>
<td bordercolor=DarkGray width=30 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Resets</font></b></td>
<td bordercolor=DarkGray width=90 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Class</font></b></td>
<td bordercolor=DarkGray width=80 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Zen</font></b></td>
<td bordercolor=DarkGray width=50 height=20 valign=top align=center><font color=black face=Tahoma><b><u>PK</font></b></td>
<td bordercolor=DarkGray width=10 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Status</font></b></td>

</tr>';

for($i=0;$i < $result->numrows();++$i)
         {
             $row = $result->fetchrow();
             $rank = $i+1;
             $rank2 = $rank+1;


if($row[1] == 0){ $row[1] ='<img src=images/0.jpg>';}
if($row[1] == 1){ $row[1] ='<img src=images/1.jpg>';}
if($row[1] == 2){ $row[1] ='<img src=images/2.jpg>';}
if($row[1] == 16){ $row[1] ='<img src=images/16.jpg>';}
if($row[1] == 17){ $row[1] ='<img src=images/17.jpg>';}
if($row[1] == 18){ $row[1] ='<img src=images/18.jpg>';}
if($row[1] == 32){ $row[1] ='<img src=images/32.jpg>';}
if($row[1] == 33){ $row[1] ='<img src=images/33.jpg>';}
if($row[1] == 34){ $row[1] ='<img src=images/34.jpg>';}
if($row[1] == 48){ $row[1] ='<img src=images/48.jpg>';}
if($row[1] == 49){ $row[1] ='<img src=images/49.jpg>';}
if($row[1] == 64){ $row[1] ='<img src=images/64.jpg>';}
if($row[1] == 65){ $row[1] ='<img src=images/65.jpg>';}
if($row[1] == 80){ $row[1] = '<img src=images/80.jpg>'; }
if($row[1] == 81){ $row[1] = '<img src=images/81.jpg>'; }
if($row[1] == 82){ $row[1] = '<img src=images/82.jpg>'; }

$acc_search="Select AccountID from Character where name='$row[0]'";
$dada=$db->Execute($acc_search);
$acc=$dada->fetchrow();
$query2="Select ConnectStat from memb_stat where memb___id='$acc[0]'";
$blabla=$db->Execute($query2);
$blabla=$blabla->fetchrow();

if($blabla[0] == '0'){ $status = "<span class='status_offline'><img src=./images/Offline.gif width=11 height=11 ></span> "; }
if($blabla[0] != '0'){ $status = "<span class='status_online'><img src=./images/Online.gif width=11 height=11 ></span> "; }

$content .="<tr>
<td height=20 valign=top align='center'><font face=Tahoma color=DimGray><b>$rank.</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><a  onmouseover=\"return overlib('<table width=108 cellpadding=0 cellspacing=0><tr><td><strong><center>$cat[1]</center><strong> </td></tr><tr><td><strong>Name: <strong>".htmlspecialchars($row[0])."</td></tr></td></tr><tr><td><tr><td><strong>Level: <strong>$row[2]</td></tr><tr><td><strong>Resets: <strong>$row[3]</td></tr><tr><td><strong>Strenght: <strong>$row[6] </td></tr><tr><td><strong>Agility:<strong>$row[7] </td></tr><tr><td><strong> Vitality: <strong>$row[8]</td></tr><tr><td><strong>Energy:<strong>$row[8]</td></table>');\" onmouseout=\"return nd();\"><font face=tahoma color=black>$row[0]</font></a></small></td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[2]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=LightSalmon><b>[<font face=Tahoma color=Gray>$row[3]<font face=Tahoma color=LightSalmon>]</td>
<td width=90 height=20 valign=top align='center'><font face=Tahoma color=DodgerBlue>$row[1]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[4]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[5]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$status</td>

</tr>";
			
          }

show($content);
?>


</table>
 
абе инсталирай първо самият уеб сайт ако нямаш инсталация инсталирай девил уеб колкото да го конфигурира в сял базата след това го изтрии и пак си сложи своя
 
  • Like
Reactions: A.ssassi.N
Пробвай така:

Code:
<?
require("config/config.php");

$query = "Select TOP 50 Name,Class,cLevel,resets,Money,PKcount,Strength,Dexterity,Vitality,Energy from Character where ctlcode !='32' and ctlcode !='8' order by resets desc ,clevel desc";

$result = $db->Execute($query);

$content ='<br><font face=Tahoma size=2><center><b>Top 50 Players</b></center></font>
<br></br>
<font color=white>
<center><table  height=0 cellspacing=1 cellpadding=1 width=480 border=0 bordercolor=DarkGray><tr> 
<td bordercolor=DarkGray width=10 height=20 valign=top align=center><font color=black face=Tahoma><b><u>ID</font></td>
<td bordercolor=DarkGray width=110 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Name</font></b></td>
<td bordercolor=DarkGray width=30 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Level</font></b></td>
<td bordercolor=DarkGray width=30 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Resets</font></b></td>
<td bordercolor=DarkGray width=90 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Class</font></b></td>
<td bordercolor=DarkGray width=80 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Zen</font></b></td>
<td bordercolor=DarkGray width=50 height=20 valign=top align=center><font color=black face=Tahoma><b><u>PK</font></b></td>
<td bordercolor=DarkGray width=10 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Status</font></b></td>

</tr>';

for($i=0;$i < $result->numrows();++$i)
         {
             $row = $result->fetchrow();
             $rank = $i+1;
             $rank2 = $rank+1;


if($row[1] == 0){ $row[1] ='<img src=images/0.jpg>';}
if($row[1] == 1){ $row[1] ='<img src=images/1.jpg>';}
if($row[1] == 2){ $row[1] ='<img src=images/2.jpg>';}
if($row[1] == 16){ $row[1] ='<img src=images/16.jpg>';}
if($row[1] == 17){ $row[1] ='<img src=images/17.jpg>';}
if($row[1] == 18){ $row[1] ='<img src=images/18.jpg>';}
if($row[1] == 32){ $row[1] ='<img src=images/32.jpg>';}
if($row[1] == 33){ $row[1] ='<img src=images/33.jpg>';}
if($row[1] == 34){ $row[1] ='<img src=images/34.jpg>';}
if($row[1] == 48){ $row[1] ='<img src=images/48.jpg>';}
if($row[1] == 49){ $row[1] ='<img src=images/49.jpg>';}
if($row[1] == 64){ $row[1] ='<img src=images/64.jpg>';}
if($row[1] == 65){ $row[1] ='<img src=images/65.jpg>';}
if($row[1] == 80){ $row[1] = '<img src=images/80.jpg>'; }
if($row[1] == 81){ $row[1] = '<img src=images/81.jpg>'; }
if($row[1] == 82){ $row[1] = '<img src=images/82.jpg>'; }

$acc_search="Select AccountID from Character where name='$row[0]'";
$dada=$db->Execute($acc_search);
$acc=$dada->fetchrow();
$query2="Select ConnectStat from memb_stat where memb___id='$acc[0]'";
$blabla=$db->Execute($query2);
$blabla=$blabla->fetchrow();

if($blabla[0] == '0'){ $status = "<span class='status_offline'><img src=./images/Offline.gif width=11 height=11 ></span> "; }
if($blabla[0] != '0'){ $status = "<span class='status_online'><img src=./images/Online.gif width=11 height=11 ></span> "; }

$content .="<tr>
<td height=20 valign=top align='center'><font face=Tahoma color=DimGray><b>$rank.</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><a  onmouseover=\"return overlib('<table width=108 cellpadding=0 cellspacing=0><tr><td><strong><center>$cat[1]</center><strong> </td></tr><tr><td><strong>Name: <strong>".htmlspecialchars($row[0])."</td></tr></td></tr><tr><td><tr><td><strong>Level: <strong>$row[2]</td></tr><tr><td><strong>Resets: <strong>$row[3]</td></tr><tr><td><strong>Strenght: <strong>$row[6] </td></tr><tr><td><strong>Agility:<strong>$row[7] </td></tr><tr><td><strong> Vitality: <strong>$row[8]</td></tr><tr><td><strong>Energy:<strong>$row[8]</td></table>');\" onmouseout=\"return nd();\"><font face=tahoma color=black>$row[0]</font></a></small></td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[2]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=LightSalmon><b>[<font face=Tahoma color=Gray>$row[3]<font face=Tahoma color=LightSalmon>]</td>
<td width=90 height=20 valign=top align='center'><font face=Tahoma color=DodgerBlue>$row[1]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[4]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[5]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$status</td>

</tr>";
			
          }

show($content);
?>


</table>

така трябва да стане и според мен. ако стана така във всички файлове трябва да го направиш. Пиши дали е станало.
 
Пробва ли кода дали стана? за all.php е.
Кажи резултата като го пробваш.

Да, но показва само херота които съм барникал с "MuEdit"!
 
Виж така

PHP:
<?
require("config/config.php");

$query = "Select TOP 50 Name,Class,cLevel,resets,Money,PKcount,Strength,Dexterity,Vitality,Energy from Character order by resets desc ,clevel desc";}

$result = $db->Execute($query);


$content ='<br><font face=Tahoma size=2><center><b>Top 50 Players</b></center></font>
<br></br>
<font color=white>
<center><table  height=0 cellspacing=1 cellpadding=1 width=480 border=0 bordercolor=DarkGray><tr> 
<td bordercolor=DarkGray width=10 height=20 valign=top align=center><font color=black face=Tahoma><b><u>ID</font></td>
<td bordercolor=DarkGray width=110 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Name</font></b></td>
<td bordercolor=DarkGray width=30 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Level</font></b></td>
<td bordercolor=DarkGray width=30 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Resets</font></b></td>
<td bordercolor=DarkGray width=90 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Class</font></b></td>
<td bordercolor=DarkGray width=80 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Zen</font></b></td>
<td bordercolor=DarkGray width=50 height=20 valign=top align=center><font color=black face=Tahoma><b><u>PK</font></b></td>
<td bordercolor=DarkGray width=10 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Status</font></b></td>

</tr>';

for($i=0;$i < $result->numrows();++$i)
         {
             $row = $result->fetchrow();
             $rank = $i+1;
             $rank2 = $rank+1;


if($row[1] == 0){ $row[1] ='<img src=images/0.jpg>';}
if($row[1] == 1){ $row[1] ='<img src=images/1.jpg>';}
if($row[1] == 2){ $row[1] ='<img src=images/2.jpg>';}
if($row[1] == 16){ $row[1] ='<img src=images/16.jpg>';}
if($row[1] == 17){ $row[1] ='<img src=images/17.jpg>';}
if($row[1] == 18){ $row[1] ='<img src=images/18.jpg>';}
if($row[1] == 32){ $row[1] ='<img src=images/32.jpg>';}
if($row[1] == 33){ $row[1] ='<img src=images/33.jpg>';}
if($row[1] == 34){ $row[1] ='<img src=images/34.jpg>';}
if($row[1] == 48){ $row[1] ='<img src=images/48.jpg>';}
if($row[1] == 49){ $row[1] ='<img src=images/49.jpg>';}
if($row[1] == 64){ $row[1] ='<img src=images/64.jpg>';}
if($row[1] == 65){ $row[1] ='<img src=images/65.jpg>';}
if($row[1] == 80){ $row[1] = '<img src=images/80.jpg>'; }
if($row[1] == 81){ $row[1] = '<img src=images/81.jpg>'; }
if($row[1] == 82){ $row[1] = '<img src=images/82.jpg>'; }

$acc_search="Select AccountID from Character where name='$row[0]'";
$dada=$db->Execute($acc_search);
$acc=$dada->fetchrow();
$query2="Select ConnectStat from memb_stat where memb___id='$acc[0]'";
$blabla=$db->Execute($query2);
$blabla=$blabla->fetchrow();

if($blabla[0] == '0'){ $status = "<span class='status_offline'><img src=./images/Offline.gif width=11 height=11 ></span> "; }
if($blabla[0] != '0'){ $status = "<span class='status_online'><img src=./images/Online.gif width=11 height=11 ></span> "; }

$content .="<tr>
<td height=20 valign=top align='center'><font face=Tahoma color=DimGray><b>$rank.</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><a  onmouseover=\"return overlib('<table width=108 cellpadding=0 cellspacing=0><tr><td><strong><center>$cat[1]</center><strong> </td></tr><tr><td><strong>Name: <strong>".htmlspecialchars($row[0])."</td></tr></td></tr><tr><td><tr><td><strong>Level: <strong>$row[2]</td></tr><tr><td><strong>Resets: <strong>$row[3]</td></tr><tr><td><strong>Strenght: <strong>$row[6] </td></tr><tr><td><strong>Agility:<strong>$row[7] </td></tr><tr><td><strong> Vitality: <strong>$row[8]</td></tr><tr><td><strong>Energy:<strong>$row[8]</td></table>');\" onmouseout=\"return nd();\"><font face=tahoma color=black>$row[0]</font></a></small></td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[2]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=LightSalmon><b>[<font face=Tahoma color=Gray>$row[3]<font face=Tahoma color=LightSalmon>]</td>
<td width=90 height=20 valign=top align='center'><font face=Tahoma color=DodgerBlue>$row[1]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[4]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[5]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$status</td>

</tr>";
			
          }

show($content);
?>


</table>
 
  • Like
Reactions: DarkEvil
Виж така

PHP:
<?
require("config/config.php");

$query = "Select TOP 50 Name,Class,cLevel,resets,Money,PKcount,Strength,Dexterity,Vitality,Energy from Character order by resets desc ,clevel desc";}

$result = $db->Execute($query);


$content ='<br><font face=Tahoma size=2><center><b>Top 50 Players</b></center></font>
<br></br>
<font color=white>
<center><table  height=0 cellspacing=1 cellpadding=1 width=480 border=0 bordercolor=DarkGray><tr> 
<td bordercolor=DarkGray width=10 height=20 valign=top align=center><font color=black face=Tahoma><b><u>ID</font></td>
<td bordercolor=DarkGray width=110 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Name</font></b></td>
<td bordercolor=DarkGray width=30 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Level</font></b></td>
<td bordercolor=DarkGray width=30 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Resets</font></b></td>
<td bordercolor=DarkGray width=90 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Class</font></b></td>
<td bordercolor=DarkGray width=80 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Zen</font></b></td>
<td bordercolor=DarkGray width=50 height=20 valign=top align=center><font color=black face=Tahoma><b><u>PK</font></b></td>
<td bordercolor=DarkGray width=10 height=20 valign=top align=center><font color=black face=Tahoma><b><u>Status</font></b></td>

</tr>';

for($i=0;$i < $result->numrows();++$i)
         {
             $row = $result->fetchrow();
             $rank = $i+1;
             $rank2 = $rank+1;


if($row[1] == 0){ $row[1] ='<img src=images/0.jpg>';}
if($row[1] == 1){ $row[1] ='<img src=images/1.jpg>';}
if($row[1] == 2){ $row[1] ='<img src=images/2.jpg>';}
if($row[1] == 16){ $row[1] ='<img src=images/16.jpg>';}
if($row[1] == 17){ $row[1] ='<img src=images/17.jpg>';}
if($row[1] == 18){ $row[1] ='<img src=images/18.jpg>';}
if($row[1] == 32){ $row[1] ='<img src=images/32.jpg>';}
if($row[1] == 33){ $row[1] ='<img src=images/33.jpg>';}
if($row[1] == 34){ $row[1] ='<img src=images/34.jpg>';}
if($row[1] == 48){ $row[1] ='<img src=images/48.jpg>';}
if($row[1] == 49){ $row[1] ='<img src=images/49.jpg>';}
if($row[1] == 64){ $row[1] ='<img src=images/64.jpg>';}
if($row[1] == 65){ $row[1] ='<img src=images/65.jpg>';}
if($row[1] == 80){ $row[1] = '<img src=images/80.jpg>'; }
if($row[1] == 81){ $row[1] = '<img src=images/81.jpg>'; }
if($row[1] == 82){ $row[1] = '<img src=images/82.jpg>'; }

$acc_search="Select AccountID from Character where name='$row[0]'";
$dada=$db->Execute($acc_search);
$acc=$dada->fetchrow();
$query2="Select ConnectStat from memb_stat where memb___id='$acc[0]'";
$blabla=$db->Execute($query2);
$blabla=$blabla->fetchrow();

if($blabla[0] == '0'){ $status = "<span class='status_offline'><img src=./images/Offline.gif width=11 height=11 ></span> "; }
if($blabla[0] != '0'){ $status = "<span class='status_online'><img src=./images/Online.gif width=11 height=11 ></span> "; }

$content .="<tr>
<td height=20 valign=top align='center'><font face=Tahoma color=DimGray><b>$rank.</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><a  onmouseover=\"return overlib('<table width=108 cellpadding=0 cellspacing=0><tr><td><strong><center>$cat[1]</center><strong> </td></tr><tr><td><strong>Name: <strong>".htmlspecialchars($row[0])."</td></tr></td></tr><tr><td><tr><td><strong>Level: <strong>$row[2]</td></tr><tr><td><strong>Resets: <strong>$row[3]</td></tr><tr><td><strong>Strenght: <strong>$row[6] </td></tr><tr><td><strong>Agility:<strong>$row[7] </td></tr><tr><td><strong> Vitality: <strong>$row[8]</td></tr><tr><td><strong>Energy:<strong>$row[8]</td></table>');\" onmouseout=\"return nd();\"><font face=tahoma color=black>$row[0]</font></a></small></td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[2]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=LightSalmon><b>[<font face=Tahoma color=Gray>$row[3]<font face=Tahoma color=LightSalmon>]</td>
<td width=90 height=20 valign=top align='center'><font face=Tahoma color=DodgerBlue>$row[1]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[4]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$row[5]</td>
<td height=20 valign=top align='center'><font face=Tahoma color=Gray><b>$status</td>

</tr>";
			
          }

show($content);
?>


</table>

Изписва ми, че:
Code:
Parse error: syntax error, unexpected '}' in C:\Program Files\xampp\htdocs\modules\rankings\all.php on line 4

Тоест
PHP:
$query = "Select TOP 50 Name,Class,cLevel,resets,Money,PKcount,Strength,Dexterity,Vitality,Energy from Character order by resets desc ,clevel desc";}
 
Изписва ми, че:
Code:
Parse error: syntax error, unexpected '}' in C:\Program Files\xampp\htdocs\modules\rankings\all.php on line 4

Тоест
PHP:
$query = "Select TOP 50 Name,Class,cLevel,resets,Money,PKcount,Strength,Dexterity,Vitality,Energy from Character order by resets desc ,clevel desc";

Така пробвай ;)
 
  • Like
Reactions: DarkEvil
Благодаря и на двама ви, адски много ми помогнахте :)
Ако мога да съм ви полезен с нещо, съм насреща! ;)
 
Благодаря и на двама ви, адски много ми помогнахте :)
Ако мога да съм ви полезен с нещо, съм насреща! ;)

имаше и по лесно решение.

Влизаш в админпанела на сайта който е root.php или влизаш и ръчно правиш от базата данни
В ранкинга да изкарва и GMs/Admins незнам точно как се падаше тая опция, но щеше да стане и така.
 
имаше и по лесно решение.

Влизаш в админпанела на сайта който е root.php или влизаш и ръчно правиш от базата данни
В ранкинга да изкарва и GMs/Admins незнам точно как се падаше тая опция, но щеше да стане и така.

Това го разбрах в последствие :) Но благодаря все пак за помощта :)