- Timestamp:
- Jan 30, 2008, 6:59:15 PM (17 years ago)
- Location:
- quests
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
quests/statistic.php
r286 r287 37 37 echo '<tr><th><a href="statistic.php?order=user&desc='.$desc.'">Jméno</a></th> 38 38 <th><a href="statistic.php?order=NumberTranslate&desc='.$desc.'" Title="Poèet pøelo¾ených questù">Pøelo¾ených</a></th> 39 <th><a href="statistic.php?order= vote&desc='.$desc.'" Title="Prùmìrná známka questù">Prùmìrná známka</a></th>39 <th><a href="statistic.php?order=Vote&desc='.$desc.'" Title="Prùmìrná známka questù">Prùmìrná známka</a></th> 40 40 <th><a href="statistic.php?order=GM&desc='.$desc.'">Oprávnìní</a></th> 41 41 <th><a href="statistic.php?order=LastLogin&desc='.$desc.'">Poslední pøipojení</a></th></tr>'; … … 64 64 + IFNULL((SELECT sum(Vote) AS Vote FROM `page_text` WHERE User = user.ID AND Complete =1),0) 65 65 + IFNULL((SELECT sum(Vote) AS Vote FROM `npc_text` WHERE User = user.ID AND Complete =1),0) 66 ) AS SumVote,(66 ) / ( 67 67 (SELECT count(Vote) AS Vote FROM `quests` WHERE User = user.ID AND Complete =1) 68 68 + (SELECT count(Vote) AS Vote FROM `page_text` WHERE User = user.ID AND Complete =1) 69 69 + (SELECT count(Vote) AS Vote FROM `npc_text` WHERE User = user.ID AND Complete =1) 70 ) AS CountText70 ) AS Vote 71 71 FROM `user` ORDER BY $order $desc"); 72 72 73 73 while ($Line = mysql_fetch_array($ID)) { 74 75 if ($Line['CountText'] <> 0) 76 $Vote = $Line['SumVote']/$Line['CountText']; 77 else $Vote = 0; 78 74 79 75 if (Licence(1)) 80 76 $Name = '<a href="user.php?user='.$Line['ID'].'">'.$Line['user'].'</a>'; … … 84 80 echo '<tr><td>'.$Name.'</td> 85 81 <td>'.$Line['NumberTranslate'].'</td> 86 <td>'.substr($ Vote, 0, 4).'</td>82 <td>'.substr($Line['Vote'], 0, 4).'</td> 87 83 <td>'.$Moderators[$Line['GM']].'</td> 88 84 <td>'.$Line['LastLogin'].'</td></tr>'; -
quests/user.php
r286 r287 34 34 + IFNULL((SELECT sum(Vote) AS Vote FROM `page_text` WHERE User = ".$_GET['user']." AND Complete =1),0) 35 35 + IFNULL((SELECT sum(Vote) AS Vote FROM `npc_text` WHERE User = ".$_GET['user']." AND Complete =1),0) 36 ) AS SumVote,(36 ) / ( 37 37 (SELECT count(Vote) AS Vote FROM `quests` WHERE User = ".$_GET['user']." AND Complete =1) 38 38 + (SELECT count(Vote) AS Vote FROM `page_text` WHERE User = ".$_GET['user']." AND Complete =1) 39 39 + (SELECT count(Vote) AS Vote FROM `npc_text` WHERE User = ".$_GET['user']." AND Complete =1) 40 ) AS CountText40 ) AS Vote 41 41 FROM `user` WHERE ID = ".$_GET['user'])); 42 42 43 if ($LineUser['CountText'] <> 0)44 $Vote = $LineUser['SumVote']/$LineUser['CountText'];45 else $Vote = 0;46 47 43 echo 'ID: <b>'.$_GET['user'].'</b><br />'; 48 44 echo 'Jméno: <b>'.$LineUser['user'].'</b><br />'; … … 51 47 echo 'Posledí IP: <b>'.$LineUser['LastIP'].'</b><br />'; 52 48 echo 'Poèet pøelo¾ených: <b>'.$LineUser['NumberTranslate'].'</b><br />'; 53 echo 'Prùmìrná známka: <b>'.$ Vote.'</b><br />';49 echo 'Prùmìrná známka: <b>'.$LineUser['Vote'].'</b><br />'; 54 50 echo 'Email: <b>'.$LineUser['Email'].'</b><br />'; 55 51 echo '<br>
Note:
See TracChangeset
for help on using the changeset viewer.