Page 1 of 1

Please Help

Posted: Sun Nov 21, 2010 7:46 pm
by dantewow
Hello Indie Staff.

For the start i want to thank you for ur greate work !

i have a problem with register page on Forsaken Sanctum 1.1
my error is this (COULD NOT REGISTER

i check the ( reguser.php) and i dont see any problem on this code. if someone know where is the problem please help me. Thank You !

Code: Select all

 $SQL = "INSERT into players( hp, stamina, maxhp, maxstamina,'$primstat','$secstat',equipmax, backpackmax, mapr, mapc, name, proname, password, email, level, credits, expe, killer, lastattacked) VALUES(`$health`,`$stamina`,'3','2','6','15','4','4','$player','$prochoice','$password','$email','1','500','0','','')";
      mysql_query($SQL) or die("could not register");

Re: Please Help

Posted: Sun Nov 21, 2010 7:55 pm
by rockinliam
Welcome to the forums.
Probably a good idea to check the names of the fields for spelling mistakes against the database, i know this can be a fairly common error for me.

Re: Please Help

Posted: Sun Nov 21, 2010 8:32 pm
by dantewow
thank you..

brr but how i got another errors ( could not register skills )

ok.. i fix register skills problem but now i get the same error.. could not register

hmm can be a problem with this table players ?

Re: Please Help

Posted: Sun Nov 21, 2010 9:58 pm
by dantewow
for now i skip the reg page for a short time...

i got another error when im trying to craft a weapon
error => Parse error: syntax error, unexpected '"' in C:\xampp\htdocs\forsaken1\crafting\craftweapon2.php on line 156 <=

line 156 is this:

Code: Select all

if ($z > 0)
	{
	 echo "<br><center><br><A href='../locations/map.php'><img src='../images/gobackbutt.png' width='150' height='50' border='0'/>";
	exit;
	}

line 156=>       if ($weapon == 'blade'){$name = 'One Handed Blade'";}
if someone can help me with this please..?

Re: Please Help

Posted: Sun Nov 21, 2010 10:20 pm
by rockinliam
You have a stray "

Code: Select all

if ($weapon == 'blade'){$name = 'One Handed Blade'";}

Code: Select all

if ($weapon == 'blade'){$name = 'One Handed Blade';}

Re: Please Help

Posted: Mon Nov 22, 2010 10:30 am
by dantewow
yes, that was the problem, thank you my friend...

Code: Select all

        if ($weapon == 'blade'){$name = 'One Handed Blade';}
	if ($weapon == '2h_blade'){$name = 'Two Handed Blade';}
	if ($weapon == 'axe'){$name = 'Axe';}
	if ($weapon == 'pole_arm'){$name = 'Pole Arm';}
	if ($weapon == 'bow'){$name = 'Bow';}
	if ($weapon == 'blunt'){$name = 'Blunt Weapon';}
	if ($weapon == 'knife'){$name = 'Knife';}
	if ($weapon == 'crossbow'){$name = 'Crossbow';}
	if ($weapon == 'light_pistol'){$name = 'Light Pistol';}
	if ($weapon == 'heavy_pistol'){$name = 'Heavy Pistol';}
	if ($weapon == 'energy_pistol'){$name = 'Energy Pistol';}
	if ($weapon == 'energy_rifle'){$name = 'Energy Rifle';}
	if ($weapon == 'light_rifle'){$name = 'Light Rifle';}
	if ($weapon == 'heavy_rifle'){$name = 'Heavy Rifle';}
	if ($weapon == 'shotgun'){$name = 'Shotgun';}
not this is correct.. there was more stray " ..

Thank you again, but now i found another error.. i stry allot of things to fix this but no success.
The next problem is this..

im trying to build a inn or a house or anithing else i get this error... ( could not add shop )
any sugestion ? :-?

and when you ar trying to harvest you get this error on line 116 but on line 116 was missing only this $ and now its ok...

line 116

Code: Select all

$illrand = $skills3[0] + 10 + $playerinfo3['iq'];
.. this is fix..

but now here is another error ( Attempting to Fish ....
You catch a . It took 1 hours.
could not add to backpack _ )

i alwyas get this error

i think is something wrong here ..

Code: Select all

	$SQL = "INSERT into backpack(id, name, type, stats, modadd,price,level,randid,consumable) VALUES ('$id','$name','$foundr3[type]','$foundr3[stats]','$mod','$foundr3[price]','$foundr3[level]','$randid','$foundr3[consumable]')"; 
      mysql_query($SQL) or die("could not add to backpack");

Re: Please Help

Posted: Tue Nov 23, 2010 2:21 pm
by hallsofvallhalla

Code: Select all

$illrand = $skills3[0] + 10 + $playerinfo3['iq'];
seems like it should be
$skillrand = $skills3[0] + 10 + $playerinfo3['iq'];
if it is not giving the fish name then it is where it is querying for the fish. Try the line where it selects all from fishmat. Check to be sure you have fishmats in your DB or whatever the fish table is called. I cant remember