mr bobbles
New member
ok so I am getting an error. I have got an or die(mysql_error()); and I am getting this 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 ''' at line 1.
1<?php
2function Get_ID($username){
3$result = mysql_query("SELECT * FROM `grpgusers` WHERE `username` = '".$username."'");
4$worked = mysql_fetch_array($result);
5return $worked['id'];
6 }
ok if you can't find anything there then here is where my or die is:
754$hexresult = mysql_query("SELECT * FROM `grpgusers` WHERE id=".$this->id."'") or die(mysql_error());
755$hex = mysql_fetch_array($hexresult);
756if ($hex['hexname'] == 1){
757$result = mysql_query("SELECT * FROM `grpgusers` WHERE ID='".$this->id."'");
758$worked = mysql_fetch_array($result);
why is it doing this to me?!
All help is, as usual, appreciated.
1<?php
2function Get_ID($username){
3$result = mysql_query("SELECT * FROM `grpgusers` WHERE `username` = '".$username."'");
4$worked = mysql_fetch_array($result);
5return $worked['id'];
6 }
ok if you can't find anything there then here is where my or die is:
754$hexresult = mysql_query("SELECT * FROM `grpgusers` WHERE id=".$this->id."'") or die(mysql_error());
755$hex = mysql_fetch_array($hexresult);
756if ($hex['hexname'] == 1){
757$result = mysql_query("SELECT * FROM `grpgusers` WHERE ID='".$this->id."'");
758$worked = mysql_fetch_array($result);
why is it doing this to me?!
All help is, as usual, appreciated.