- Timestamp:
- Apr 12, 2010, 8:00:41 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/statistic.php
r448 r449 3 3 include('includes/global.php'); 4 4 5 if (array_key_exists('Version',$_GET)) 6 $_SESSION['StatVersion'] = $_GET['Version']; 7 else 8 if (!array_key_exists('StatVersion',$_SESSION)) 9 $_SESSION['StatVersion'] = $Config['Web']['GameVersion']; 5 if(array_key_exists('Version', $_GET)) $_SESSION['StatVersion'] = $_GET['Version']; 6 if(!array_key_exists('StatVersion', $_SESSION)) $_SESSION['StatVersion'] = $Config['Web']['GameVersion']; 10 7 11 8 function ShowStatTable() … … 57 54 $Total += $Group['Total']; 58 55 } 59 if ($Total <> '') 60 echo('<tr><td><strong>Celkem</strong></td><td><strong>'.$Translated.'</strong></td><td><strong>'.$Total.'</strong></td><td><strong>'.ProgressBar(150, round($Translated / $Total * 100, 2)).'</strong></td></tr>'); 61 else 62 echo('<tr><td><strong>Celkem</strong></td><td><strong>'.$Translated.'</strong></td><td><strong>'.$Total.'</strong></td><td><strong>'.ProgressBar(150, 0).'</strong></td></tr>'); 56 if($Total <> 0) $TotalCount = round($Translated / $Total * 100, 2); 57 else $Total = 0; 58 echo('<tr><td><strong>Celkem</strong></td><td><strong>'.$Translated.'</strong></td><td><strong>'.$Total.'</strong></td><td><strong>'.ProgressBar(150, $Total).'</strong></td></tr>'); 63 59 echo('</table>'); 64 60 } … … 66 62 ShowPage(); 67 63 68 $ConfigVersion = $Config['Web']['GameVersion']; 69 echo ('Zobrazit statistiku pro verzi: <br />'); 70 echo ('<a href="?Version=2.4.3">2.4.3</a> '); 71 $DbResult = $Database->SQLCommand('SELECT Version, Title FROM `ClientVersion` WHERE BuildNumber > 8209 AND Title <> "" ORDER BY Version'); 72 while($DbRow = mysql_fetch_assoc($DbResult)) 73 { 74 if ($DbRow['Version'] == $Config['Web']['GameVersion']) $ConfigVersion = false; 75 echo ('<a href="?Version='.$DbRow['Version'].'" Title="'.$DbRow['Title'].'">'.$DbRow['Version'].'</a> '); 76 } 77 $DbResult = $Database->SQLCommand('SELECT MAX(Version) as max FROM `ClientVersion`'); 78 $DbRow = mysql_fetch_assoc($DbResult); 79 if (($ConfigVersion <> false) and ($ConfigVersion <> $DbRow['max'])) echo ('<a href="?Version='.$ConfigVersion.'">'.$ConfigVersion.'</a> '); 80 echo ('<a href="?Version='.$DbRow['max'].'">'.$DbRow['max'].'</a> '); 64 // Show client version selection 65 echo('Zobrazit statistiku pro verzi: '); 66 $DbResult = $System->Database->query('SELECT `Version`, `Title` FROM `ClientVersion` WHERE `Imported`=1 ORDER BY `Version`'); 67 while($DbRow = $DbResult->fetch_assoc()) 68 { 69 echo('<a href="?Version='.$DbRow['Version'].'" title="'.$DbRow['Title'].'">'.$DbRow['Version'].'</a> '); 70 } 81 71 82 echo('<h3>Statistika dokončení překladů pro verzi '.$_SESSION['StatVersion'].'</h3><br/>Jazyk: <a href="statistic.php">Dohromady</a>'); 72 // Show language selection 73 echo('<br /><br /><h3>Statistika dokončení překladů pro verzi '.$_SESSION['StatVersion'].'</h3><br/>'); 74 echo('Jazyk: <a href="statistic.php">Dohromady</a>'); 83 75 foreach($LanguageList as $Language) 84 76 if($Language['Enabled'] == 1) echo(' <a href="?language='.$Language['Id'].'">'.$Language['Name'].'</a>');
Note:
See TracChangeset
for help on using the changeset viewer.