hi,
habe folgenden code
es komtm aber immer Parse error: syntax error, unexpected T_VARIABLE in C:\xampp\htdocs\reps\replay\php_bw_load_replay.php on line 15
wenn ich es aber so mache also die ezeien die ich brauche weg lasse gehts
so gehts ohne Probleme
habe folgenden code
PHP:
<?php
$pfad = preg_replace("/[^a-zA-Z0-9.,\-_]/","",$_GET['path']);
?>
<?php
chdir('replays/'); // <-- die zeile hier einfügen in deinem script
$info = php_bw_load_replay(getcwd()."/".$pfad); // <-- die zeile ändern in deinem script
// rest ist gleich geblieben ...
$map = $info->Map;
$team = $info->Teams
$player =$info->Players;
if($info->ErrorCode != 0)
die("Could not load the replay ! Message : " . $info->ErrorString);
echo date("d.m.Y",$info->GameDate);
echo "<br>Number of Players :" . $info->NumPlayer;
echo "<br>Teams :" . $info->Teams;
echo"<br>winner:" . $winner->Name;
echo "<br>matchup :" . $info->Matchup;
echo"<br>Spiel Dauer: "; echo date("i:s",$info->GameLength);echo ' min';
echo"<br>Type: " .$info->GameType;
echo "<br>Mapname : " . $map->Name;
echo "<br>Gamename : " . $info->GameName;
echo "<br>Players info : <br>";
foreach($info->Players as $player)
echo $player->Name . " : " . "<img src='img/".$player->RaceName.".png'>" . ", " . $player->IsObserver . "," . $player->ColorName . "," . $player->APM . "APM.<br>";
$team1 = $team[0];
$team2 = $team[1];
echo $team1[0];
foreach($info->Teams as $team)
{
echo "<hr>";
foreach($team as $ppl)
{
echo $ppl."<br>";
}
}
?>
es komtm aber immer Parse error: syntax error, unexpected T_VARIABLE in C:\xampp\htdocs\reps\replay\php_bw_load_replay.php on line 15
wenn ich es aber so mache also die ezeien die ich brauche weg lasse gehts
PHP:
<?php
$pfad = preg_replace("/[^a-zA-Z0-9.,\-_]/","",$_GET['path']);
?>
<?php
chdir('replays/'); // <-- die zeile hier einfügen in deinem script
$info = php_bw_load_replay(getcwd()."/".$pfad); // <-- die zeile ändern in deinem script
// rest ist gleich geblieben ...
$map = $info->Map;
$player =$info->Players;
if($info->ErrorCode != 0)
die("Could not load the replay ! Message : " . $info->ErrorString);
echo date("d.m.Y",$info->GameDate);
echo "<br>Number of Players :" . $info->NumPlayer;
echo "<br>Teams :" . $info->Teams;
echo "<br>matchup :" . $info->Matchup;
echo"<br>Spiel Dauer: "; echo date("i:s",$info->GameLength);echo ' min';
echo"<br>Type: " .$info->GameType;
echo "<br>Mapname : " . $map->Name;
echo "<br>Gamename : " . $info->GameName;
echo "<br>Players info : <br>";
?>