i got some help via google
hers the city.php:
Code: Select all
<?php
include_once 'connect.php';
session_start();
include_once 'logo.php';
?>
<link href="style.css" rel="stylesheet" type="text/css" />
<div id="login2" div align="center">
<?php
if (isset($_SESSION['player']))
{
$player=$_SESSION['player'];
}
else
{
echo "Not Logged in <br><br> <A href='login.php'>Login</a>";
exit;
}
$data = mysql_query("SELECT * FROM picture")
or die(mysql_error());
while($info = mysql_fetch_array( $data ))
{
print "<div style='text-align:left; padding-bottom:30px; margin-left:20px;'>";
print " " . $info["Picture"] . "";
print "</div>";
}
?>
</div>
<div id ="locations">
<?php
$playerinfo="SELECT * from players where name='$player'";
$playerinfo2=mysql_query($playerinfo) or die("could not get player stats!");
$playerinfo3=mysql_fetch_array($playerinfo2);
$playerhp = $playerinfo3['hpoints'];
if ($playerhp < 1)
{
echo "You are dead!" ;
echo "<br><a href='useitem.php>Use an Item";
exit;
}
echo "<b><big><u>Locations</u></big></b><br>";
echo "<a href='store.php'>Visit Store<br>";
echo "<a href='battle.php'>Battle in Arena<br>";
?>
</div>
<div id="logout">
<?php
echo "<br><a href='logout.php'><img src='images/logout.gif'>";
?>
</div>
sampel:
http://www.stargate-sg1.dk/lasse/image/123456vi.jpg
how the sampel picture is showing. just need to do it so its a unique img , so each player can have picture not looking the same
