SMF 1.1.4SMF Shop Mod 3 (Build 12)SMF Pets Version 0.2SMFShop Inventory Post Mod Version 0.2SMFShop Stats Mod Version 0.1\---------------------\
My shop all of a sudden stopped working over night. I hadn't changed anything in the code prior (It was working, and when I came back to further train my pet I got the following 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 's the best! Built for Battle!',
hunger = 8,
age = 1,
' at line 7
File: /home/content/x/x/x/xxxxx/html/smf/Sources/shop/pet_engine.php
Line: 305
On top of that, my pet is somehow 21 days old and Very Depressed / Starving. (I can still see my pet through my UserCP). My pet in actuality is only 2-3 days old.
I have attached the code of the pet_engine.php to this thread:
----
Furthermore, the section that it says it has a problem with is here:
290 //Store the values back into the database(very important)
291 function store_values() {
292 global $db_prefix;
293 $result = db_query("UPDATE {$db_prefix}shop_pets
294 SET name = '{$this->name}',
295 level = {$this->level},
296 curap = {$this->curap},
297 maxap = {$this->maxap},
298 happy = {$this->happy},
299 `desc` = '{$this->desc}',
300 hunger = {$this->hunger},
301 age = {$this->age},
302 training = {$this->training},
303 trainingend = '{$this->trainingend}',
304 ownerid = {$this->ownerid}
305 WHERE pet_id = {$this->id}", __FILE__, __LINE__);
306 }
Thanks in advance