Jump to content

gevensen

Members
  • Posts

    206
  • Joined

  • Last visited

Everything posted by gevensen

  1. have you tried assigning the row id to a variable right after the 1st call and using that variable later, kind of a saved point of reference?
  2. OK thanks all It had to do with the symbol ` instead of ' Its working now
  3. yes i just noticed that also and was coming back to note that but now i am getting another error it says Unknown column 'BILL SMITH' in 'field list' Bill Smith is the user I am adding which is the variable $saved_name $sql_insert2="UPDATE `masterlogin`.`sc_users` SET `name` = `$saved_name`, `username` = `$user_name`, `password` = `$encrypted_password`, `db`=`$db`, `email` = `$saved_email`, `dateregistered` = `$today`, `picture_name` = `$picname`, `super_admin` = `$super_admin`, `full_admin` = `$full_admin`, `data_entry` = `$data_entry`, `report_access` = `$report_access`, `audit` = `$audit`, `departmental_reviews` = `$departmental`, `department` = `$department`, `added_by` = `$added_by`, `admin_db` = `$admin_db` WHERE `sc_users`.`id` = '$pulled_id'";
  4. DOYYYY..... I cant beleive i missed that But im still getting an error after fixing that 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 'WHERE `sc_users`.`id` = `70` LIMIT 1' at line 17
  5. I am having a problem with my syntax in a mysql_query command I get the error message 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 '`departmental_reviews` = `1`, `department` = `General`, `added_by` = `geve' at line 13 The syntax im using is: $sql_insert="UPDATE `masterlogin`.`sc_users` SET `name` = `$saved_name`, `username` = `$user_name`, `password` = `$encrypted_password`, `db`=`$db`, `email` = `$saved_email`, `dateregistered` = `$today`, `picname`=`$picname`, `super_admin`= `$super_admin`, `full_admin` = `$full_admin`, `data_entry` = `$data_entry`, `report_access` = `$report_access`, `audit` = `$audit` `departmental_reviews` = `$departmental`, `department` = `$department`, `added_by` = `$added_by`, `admin_db` = `$admin_db`, WHERE `sc_users`.`id` = $pulled_id LIMIT 1 "; Any idea what im doing wrong? I notice that the phpmyadmin uses ` instead of ' but i have tried it both ways it was working until i added a couple of fields, they are all in the database though and spelled properly
  6. i am trying to run a report on a sunshop shopping cart table the data is base 64 endoded and serialized i get the following result after doing a base64decode and unserialize __PHP_Incomplete_Class Object ( [__PHP_Incomplete_Class_Name] => item [id] => 20 [quantity] => 1 [options] => Array ( ) [regid] => ) i am mainly looking for item id and quantitiy which is in there my question is this how do i remove the __PHP_Incomplete_Class Object error when i dont know the original class name the code blow simply dumps the data on the screen and row[4] is the problem string while($row=mysql_fetch_array($result)) { $return[] = $row; echo(" OrderID - "); print_r($row[1]); echo(" ProductID - "); print_r($row[2]); echo(" Price - "); print_r($row[3]); echo(" Data Array - "); $product_array = unserialize(base64_decode($row[4])); echo nl2br("\n"); echo(" Trying to Unserialize "); echo nl2br("\n"); print_r($product_array); }
×
×
  • 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.