Merchant
Expert Mapper
- Joined
- Mar 12, 2008
- Messages
- 769
- Reaction score
- 20
I want the script to show, vocation, residence and position.
But it seems that it shows the vocation ID, and nothing atht eresidence and position.
This is my codes:
I'll be glad for some help as fast as possible!
Merchant.
But it seems that it shows the vocation ID, and nothing atht eresidence and position.
This is my codes:
Code:
<?
////////////////////////////////////
// Script
////////////////////////////////////
if(empty($_GET["name"])){
echo "<script src=\"ajax/javascript_search.js\"></script>\n";
echo "<h3>Search player:</h3>\n";
echo "<form method=\"post\">\n";
echo "<p>Name: <input name=\"search_name\" OnKeyUp=\"showHint(this.value)\"></p>\n";
echo "<p>Suggestions: <span id=\"txtHint\"></span></p> ";
echo "<p><input type=\"submit\" value=\"Search\"></p>\n";
echo "</form>\n";
echo $player_dont_exist;
}else{
$name = preg_replace("/_/", " ", $_GET["name"]);
$player_data = mysql_query("SELECT * FROM players WHERE name='$name'") or die(mysql_error());
if (mysql_num_rows($player_data) == 0){
echo "<h3>Player dont exist!</h3>\n";
}else{
$data = mysql_fetch_array( $player_data );
echo "<h3>".$name.": </h3>\n";
echo "<p>Level: ".$data['level']."</p>\n";
echo "<p>Vocation: ".$data['vocation']."</p>\n";
echo "<p>Magic level: ".$data['maglevel']."</p>\n";
echo "<p>Recidence: Under Construction ".$data['townid']."</p>\n";
echo "<p>Position: <red>Under Construction<red> ".$data['groupid']."</p>\n";
$id = $data['id'];
$player_skills = mysql_query("SELECT * FROM player_skills WHERE player_id='$id'") or die(mysql_error());
while($data = mysql_fetch_array( $player_skills)){
switch($data['skillid']){
}
}
}
}
?>
I'll be glad for some help as fast as possible!
Merchant.