Jump to content

[SOLVED] cant figure it out


oldspicelong

Recommended Posts

below is the code including the html and i cant figure out what is wrong with the php script

 

<?php

mysql_connect("mysql", "notforyou", "notforyou") or die(mysql_error());
mysql_select_db("notforyou") or die(mysql_error());

$username = $_COOKIE['ID_my_site'];


$sql = mysql_query("SELECT * FROM users WHERE username = '$username'");
$row = mysql_fetch_array($sql);
if($row['rank'] == Jonin){
mysql_query("UPDATE `users` SET `rank` = 'Akatsuki' WHERE username = '$username'") or die(mysql_error());
echo '<center>You have become a member of the Akatsuki . '.$username.'</center>';
}else{
echo '<center>Your not qualified enough for this job.</center>';

}

                    echo "Name:".$row['username']."<br/>";
                    echo "Level:".$row['level']."<br/>";
?>

Link to comment
https://forums.phpfreaks.com/topic/169038-solved-cant-figure-it-out/
Share on other sites

below is the code including the html and i cant figure out what is wrong with the php script

If you dont know, how are we supposed to know. :D

 

Can you explain what you're trying to do, tell use what the script is supposed to do, what it doing now and post any errors you get here in full

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.