Jump to content
MakeWebGames

Job edit bug in MCcode V2 help!


chaoswar4u
 Share

Recommended Posts

In staff panel if you use the edit job rank link you will enter for the information. When you submit the changes you get this error.

QUERY ERROR: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'jrID=' at line 1

Query was UPDATE jobranks SET jrNAME='Captain', jrJOB = 3, jrPAY= 2000, jrIQG=26, jrLABOURG=26, jrSTRG=26, jrIQN=16225, jrLABOURN=16225, jrSTRN=16225WHERE jrID=

The code around this is

function jobrankedit()

{

global $db,$ir,$userid;

if ( $_POST['stage2']) {

$db->query("UPDATE jobranks SET jrNAME='{$_POST['jrNAME']}', jrJOB = {$_POST['jrJOB']}, jrPAY= {$_POST['jrPAY']}, jrIQG={$_POST['jrIQG']}, jrLABOURG={$_POST['jrLABOURG']}, jrSTRG={$_POST['jrSTRG']}, jrIQN={$_POST['jrIQN']}, jrLABOURN={$_POST['jrLABOURN']}, jrSTRN={$_POST['jrSTRN']}WHERE jrID={$_POST['jrID']}");

print "Job rank updated!

";

}

 

Any help would be great. Thx

Link to comment
Share on other sites

  • 2 months later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...