Welcome to the Browser-Base Game Zone forums!
I can send you pics of my cocks if you want reference.
I'm so nice that I'll give you a simple poker script but you need to edit the core around it. I'm not doing that. Just give me a day to find it from my archives..
I did remove the script, even when it was very simple one, until this mess is settled up. You really should be able to do the poker script by your own. Hell, think of it as a lesson to array manipulation.
function famforum(){$player = $_SESSION['playername'];$qry = mysql_query("SELECT * FROM `players` WHERE `playername` = '$player' LIMIT 1")or die(mysql_error());$arr = mysql_fetch_array($qry);$family = $arr['family'];if ($family != "None"){$q = mysql_query("SELECT `location` FROM `family` WHERE `name` = '$family' LIMIT 1")or die(mysql_error());$a = mysql_fetch_array($q);$loc = $a['0'];print (" <a href=\"forum/forum.php?forum=".$loc."\" target=\"main\">Family forum</a><br />");}elseif ($family == "None"){print (" <a href=\"forum/forum.php?forum=family\" target=\"main\">Family forum</a><br />");}}?>
Here, I coded this a few days ago. Its for my menu. My game has thier own family forum each. There is a limit to one family per location so it works by locations. So if I'm not in a family it will point me to forum.php?forum=familyIf I was in a family it would point me to the location where my family was made. So only people in the family x can view that locations forum. Each family would have thier own family forum like they have thier own location..There P.S :: Rushed the text above, times up once again. Code: [Select]function famforum(){$player = $_SESSION['playername'];$qry = mysql_query("SELECT * FROM `players` WHERE `playername` = '$player' LIMIT 1")or die(mysql_error());$arr = mysql_fetch_array($qry);$family = $arr['family'];if ($family != "None"){$q = mysql_query("SELECT `location` FROM `family` WHERE `name` = '$family' LIMIT 1")or die(mysql_error());$a = mysql_fetch_array($q);$loc = $a['0'];print (" <a href=\"forum/forum.php?forum=".$loc."\" target=\"main\">Family forum</a><br />");}elseif ($family == "None"){print (" <a href=\"forum/forum.php?forum=family\" target=\"main\">Family forum</a><br />");}}?>-Sean
Quote from: Slashmore on February 15, 2009, 06:27:35 PMHere, I coded this a few days ago. Its for my menu. My game has thier own family forum each. There is a limit to one family per location so it works by locations. So if I'm not in a family it will point me to forum.php?forum=familyIf I was in a family it would point me to the location where my family was made. So only people in the family x can view that locations forum. Each family would have thier own family forum like they have thier own location..There P.S :: Rushed the text above, times up once again. Code: [Select]function famforum(){$player = $_SESSION['playername'];$qry = mysql_query("SELECT * FROM `players` WHERE `playername` = '$player' LIMIT 1")or die(mysql_error());$arr = mysql_fetch_array($qry);$family = $arr['family'];if ($family != "None"){$q = mysql_query("SELECT `location` FROM `family` WHERE `name` = '$family' LIMIT 1")or die(mysql_error());$a = mysql_fetch_array($q);$loc = $a['0'];print (" <a href=\"forum/forum.php?forum=".$loc."\" target=\"main\">Family forum</a><br />");}elseif ($family == "None"){print (" <a href=\"forum/forum.php?forum=family\" target=\"main\">Family forum</a><br />");}}?>-SeanThat works, but its very unoptimal. Now, try to make that with one query and in 10 lines of code instead of 20+.