Beides probiert. Gleiches Problem. Hab nun mal die blank_home genommen. Was könnte da falsch sein ?
<?php // $Id: index.php,v 1.3 2005/08/30 07:10:58 tora60 Exp $
/************************************
pragmaMx Content Management System
Copyright (c) 2005 pragmaMx Dev Team - http://pragmaMx.org
***********************************
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
***********************************
$Source: /home/www/dps3311/home/cvsroot/pragmamx/html/modules/blank_Home/index.php,v $
$Revision: 1.3 $
$Author: tora60 $
$Date: 2005/08/30 07:10:58 $
************************************/
if (!defined("mxMainFileLoaded")) die ("You can't access this file directly...");
$GLOBALS["index"] = 1;
/* if (isset($show)) {
$output = "";
$file = @fopen($show, "r");
if ($file){
while (!feof($file)) {
$output .= " ".trim(fgets($file, 1024))." ";
}
fclose($file);
}
#$output = strip_tags(trim($output));
$output = trim($output);
}
*/
include("header.php");
include("dbinfo.inc.php");
$order=$_GET["order"];
$sort=$_GET["sort"];
if($sort=="DESC") {
$sort="ASC";
} else {
$sort="DESC";
}
if($order=="good") {
$order="(good/total)*100";
} else if($order=="okay") {
$order="(okay/total)*100";
} else if($order=="bad") {
$order="(bad/total)*100";
} else if($order==""){
$order="total";
}
mysql_connect($host,$username,$password);
@mysql_select_db($database) or die( "Unable to select database");
$query="SELECT * FROM `maprank` ORDER BY ".$order." ".$sort." ";
$result=mysql_query($query);
$num=mysql_numrows($result);
mysql_close();
echo "<b><br><center><font size=+2>Map Bewertungen</center></b><font size=-2><br>";
?>
<BODY BGCOLOR="#000000" TEXT="#eeeeee" LINK="#99CCFF" VLINK="#99CCFF" ALINK="#99CCFF" leftmargin=0 rightmargin=0 topmargin=0 bottommargin=0 marginheight=0 marginwidth=0>
<div align="center">
<table border="2" cellspacing="2" cellpadding="2" width="100%">
<tr>
<?
echo "<th align='center'><a href='".$home_site."index.php?order=map_name&sort=".$sort."'><font size=+1>Map Name</font></a></th>
<th align='center'><a href='".$home_site."index.php?order=good&sort=".$sort."'><font size=+1>Gut</font></a></a></th>
<th align='center'><a href='".$home_site."index.php?order=okay&sort=".$sort."'><font size=+1>Okay</font></a></th>
<th align='center'><a href='".$home_site."index.php?order=bad&sort=".$sort."'><font size=+1>Schlecht</font></a></th>
<th align='center'><a href='".$home_site."index.php?order=total&sort=".$sort."'><font size=+1>Votes</font></a></th>
</tr>";
?>
<?
$i=0;
while ($i < $num) {
$map_name=mysql_result($result,$i,"map_name");
$state1=mysql_result($result,$i,"good");
$state2=mysql_result($result,$i,"okay");
$state3=mysql_result($result,$i,"bad");
$total=($state1 + $state2 + $state3);
if ($total==0){
$state1p=0;
}else{
$state1p=round($state1 / $total,2)*100;
}
if ($total==0){
$state2p=0;
}else{
$state2p=round($state2 / $total,2)*100;
}
if ($total==0){
$state3p=0;
}else{
$state3p=round($state3 / $total,2)*100;
}
$color="a0a020";
if (($state1p >= $state2p) & ($state1p > $state3p)){
$color="208020";
}
if (($state3p >= $state2p) & ($state3p > $state1p)){
$color="802020";
}
echo "<tr>
<td align='center'><font color='".$color."'>".$map_name."</font></td>
<td align='center'><font color='a0a0a0'>".$state1p."%</font></td>
<td align='center'><font color='a0a0a0'>".$state2p."%</font></td>
<td align='center'><font color='a0a0a0'>".$state3p."%</font></td>
<td align='center'><font color='a0a0a0'>".$total."</font></td>
</tr>";
++$i;
}
echo "</table>";
include("footer.php");
?>