Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

[Help]MapleSpark vote script.

Junior Spellweaver
Joined
Jan 29, 2011
Messages
151
Reaction score
5
sorry for being such a noob but im not good php coder so could you guys tell me whats wrong with this script? no matter what i do, i get "Please type in info corectly"?

Code:
<?php
include("nxconfig.php");
if (array_key_exists('reset', $_POST)) {

  $username = trim($_POST['username']);
  $password = trim($_POST['password']);
  $username = mysql_real_escape_string($username);
  $char = trim($_POST['char']);
  $mesocheck = mysql_query('SELECT * FROM meso FROM characters');
  $result = mysql_query("SELECT meso, accountid FROM characters WHERE name = '$char' LIMIT 1");
  list($meso, $accountid) = mysql_fetch_row($result);

  $result = mysql_query("SELECT id, password, salt FROM accounts WHERE name = '$username' LIMIT 1");
  list($id, $realpass, $salt) = mysql_fetch_row($result);

  $sql = "SELECT * FROM accounts WHERE name = '$username'";
  $result = mysql_query($sql);
  $row = mysql_fetch_assoc($result);
    
if($realpass == hash('sha512',$password.$salt) && $accountid == $id) {
     mysql_query("UPDATE accounts SET cardNX = cardNX + 5000 WHERE name = '$username' LIMIT 1");
     echo '<html><frameset rows="*,0" framespacing="0" border="0" frameborder="NO"><frame src="http://www.xtremetop100.com/in.php?site=1132257845" scrolling="auto" noresize></frameset><noframes><body></body></noframes></html>';
    } else {
     echo "<center>Please Type Your Info Correctly..</center>";    }
    }
?>
       <div align="center"><h1>Vote for 5.000 NX points!</h1></div>
<br>
          <div align="center">
          <div class="display">
<?php
if (isset($message)) {
  echo '<ul>';
  foreach ($message as $item) {
    echo "<li>$item</li>";
    }
  echo '</ul>';
  }
?>
           </div>
              <form id="form1" name="form1" method="post" action="">
                    <table cellspacing="0" cellpadding="5" width="100%">
                  <tr>
                            <td width="50%" align="right" class="list">Account :</td>
                          <td class="list"><input id="username" type="text" name="username" maxlength="12"></td>
                        </tr>
                        <tr>
                          <td width="50%" align="right" class="list">Password :</td>
                          <td class="list"><input id="password" type="password" name="password" maxlength="20" /></td>
                        </tr>
                        <tr>
                            <td width="50%" align="right" class="list">Character:</td>
                          <td align="left" class="list"><input id="char" type="text" name="char" maxlength="12"></td>
                        </tr>
                        <tr>
                          <td align="center" colspan="2"><input id="reset" name="reset" type="submit" value="Vote!" /></td>
                        </tr>
                    </table>
            </form>
            </div>

anyone?
 
Mythic Archon
Joined
Dec 25, 2011
Messages
723
Reaction score
97
Wrong section. As this is PHP, you are required to post in the alternative languages section.
 
Upvote 0
Back
Top