Jump to content
MakeWebGames

SouIAssassin

Members
  • Posts

    38
  • Joined

  • Last visited

    Never

Everything posted by SouIAssassin

  1. Re: [REVIEW] Dark Streets Is Almost Complete Please Review register is now fixed thabnks
  2. Re: Crystal market with limit and day function well doing it on hours would keep them active really sorry i don't seem to know what i have done wrong sorry guys
  3. Re: Crystal market with limit and day function it shoudl be set in the cron hour sorry for the error
  4. Re: not sure about this iam not saying its going to be rubbish or anything but in that stament all your saying is that your doing name changes and stuff like that like brave into guts etc etc ...
  5. Re: Visability if($ir['level'] > 4) { echo 'Bank'; } means lvls above 4 will see it
  6. Re: Will,Brave and energy some cron have to be set up to wget and it might work
  7. Re: Look at this please hey m8 you need to look at your gangs table in your database and you have o have the say number of feilds as like your insret into lnto I.E if you have 15 like mine then it has to be   $db->query("INSERT INTO gangs VALUES('','$name','$desc','','',0,0,100,$userid,$userid,5,0,0,'',0)"); in order it is the gangid gang name gang desc gang perf gang suff gang money gang crystals gang president gang vice president gang capacity gang crime gang chours gang ament gang amoury if you don't have a gang amoury just take the ,0 from the end of the query so it would now be.   $db->query("INSERT INTO gangs VALUES('','$name','$desc','','',0,0,100,$userid,$userid,5,0,0,'')"); the '' inside the vaules are ' ' not " hope that helps
  8. Re: Crystal market with limit and day function yes thats what i ment thank you mrgi thank you for correcting that for me m8 ;)
  9. Re: Crystal market with limit and day function its not a 3 crystal limit its like a 3 post max if u know what i mean
  10. Re: [mccode v2] Site lockdown back on topic the mod worked first time nice 1 ;)
  11. Re: Help on line 45 there might be a print missing a "; or just a ; at the end iam not too sure but past your line 44-47 code here and i can look at see
  12. Re: [mccode v2] Advanced(isher) Level Upgrade Mod. i like how someone always goes back to the point and all the coders and hackers i have spoke to i have never heard any of them say to me when coding don't use veribles becasue they can get hack this is the first i have heard of it can u give me another demo on how this can be done ;)
  13. What This Update Does It Lets Gang Owner Send A Mass Payment In Crystals As Well As Money. Open YourGang.php Find. [url='yourgang.php?action=staff&act2=masspayment']Mass Payment[/url]   Replace With. [url='yourgang.php?action=staff&act2=masspayment']Mass Payment(Money)[/url] [url='yourgang.php?action=staff&act2=masspaymentcry']Mass Payment(Crystals)[/url]   Nexted Find case "masspayment": gang_staff_masspayment(); break;   Add Under case "masspaymentcry": gang_staff_masspaymentcry(); break;   Then Find function gang_staff_masspayment() { global $db,$ir,$c,$userid,$gangdata; $_POST['amnt']=abs((int) $_POST['amnt']); if($_POST['amnt']) { $q=$db->query("SELECT * FROM users WHERE gang={$ir['gang']}"); while($r=$db->fetch_row($q)) { if($gangdata['gangMONEY'] >= $_POST['amnt']) { event_add($r['userid'],"You were given \${$_POST['amnt']} from your gang.",$c); $db->query("UPDATE users SET money=money+{$_POST['amnt']} WHERE userid={$r['userid']}", $c); $gangdata['gangMONEY']-=$_POST['amnt']; print "Money sent to {$r['username']}. "; } else { print "Not enough in the vault to pay {$r['username']}! "; } } $db->query("UPDATE gangs SET gangMONEY={$gangdata['gangMONEY']}, gang WHERE gangID={$ir['gang']}", $c); $db->query("INSERT INTO gangevents VALUES('',{$ir['gang']},unix_timestamp(), 'A mass payment of \${$_POST['amnt']} was sent to the members of the Gang.')"); print "Mass payment sending complete! [url='yourgang.php?action=staff']> Back[/url]"; } else { print "[b]Mass Payment[/b] <form action='yourgang.php?action=staff&act2=masspayment' method='post'> Amount: <input type='text' name='amnt' /> <input type='submit' value='Send' /></form>"; } }   And Under function gang_staff_masspaymentcry() { global $db,$ir,$c,$userid,$gangdata; $_POST['amnt']=abs((int) $_POST['amnt']); if($_POST['amnt']) { $q=$db->query("SELECT * FROM users WHERE gang={$ir['gang']}"); while($r=$db->fetch_row($q)) { if($gangdata['gangCRYSTALS'] >= $_POST['amnt']) { event_add($r['userid'],"You were given {$_POST['amnt']} crystals from your gang.",$c); $db->query("UPDATE users SET crystals=crystals+{$_POST['amnt']} WHERE userid={$r['userid']}", $c); $gangdata['gangCRYSTALS']-=$_POST['amnt']; print "Crystals sent to {$r['username']}. "; } else { print "Not enough in the vault to pay {$r['username']}! "; } } $db->query("UPDATE gangs SET gangCRYSTALS={$gangdata['gangCRYSTALS']} WHERE gangID={$ir['gang']}", $c); $db->query("INSERT INTO gangevents VALUES('',{$ir['gang']},unix_timestamp(), 'A mass payment of {$_POST['amnt']} crystals was sent to the members of the Gang.')"); print "Mass payment sending complete! [url='yourgang.php?action=staff']> Back[/url]"; } else { print "[b]Mass Payment(Crystals)[/b] <form action='yourgang.php?action=staff&act2=masspaymentcry' method='post'> Amount: <input type='text' name='amnt' /> <input type='submit' value='Send' /></form>"; } }   Find { print "[b]Mass Payment[/b] <form action='yourgang.php?action=staff&act2=masspayment' method='post'> Amount: <input type='text' name='amnt' /> <input type='submit' value='Send' /></form>"; } }   Replace with { print "[b]Mass Payment (Money)[/b] <form action='yourgang.php?action=staff&act2=masspayment' method='post'> Amount: <input type='text' name='amnt' /> <input type='submit' value='Send' /></form>"; } }   Thats It Can You Tell Me Any Problems You Have With It And If Its Not Secure Can Someone Please Do It As Am Not Goot With Secureity :s Hope You Like It.
  14. Re: [McCodes v2] ($3) Database driven voting script with incentive and security guys what everyone else has said honeslty i have never seen a voating mod like this top notice secrity and support the guy is amzing ths mod should be more thats its worth come on bargin price is worth more than $3 and suggest you raise it becasue the other voting mods are no were near as good as this really guys get it you have to i jsut want to say that every game owner should get this most its f**king amzing and if you don't your a fool
  15. Re: [mccodes] Battle Mechs [$15] hey breaking light i would like to get the mod plz add me to msn [email protected] or mail me [email protected]
  16. Re: [REVIEW] Dark Streets Is Almost Complete Please Review i don't advertise on other games but i can't stop my members doing it can i so dnt every accuse me of asvertising on other games when i don't get your facts right before judgeing
  17. Re: [mccode v2] Ajax Chat my edition how do you get smiles to work on thses chat scripts
  18. Re: Easy Help Tutorial With Admin Feature you need to add the SQL
  19. Re: Easy Help Tutorial With Admin Feature sorry
  20. Re: Easy Help Tutorial With Admin Feature yeah i know oppes :P
  21. Re: Crystal market with limit and day function fixed with more security thanks to badgirl   <?php include "globals.php"; print "<h3>Crystal Market</h3>"; $_GET['ID'] = abs(intval($_GET['ID'])); switch($_GET['action']) { case "buy": crystal_buy(); break; case "remove": crystal_remove(); break; case "add": crystal_add(); break; default: cmarket_index(); break; } function cmarket_index() { global $db,$ir,$c,$userid,$h; print "[url='cmarket.php?action=add']> Add A Listing[/url] Viewing all listings... <table width=75% cellspacing=1 class='table'> <tr style='background:gray'> <th>Adder</th> <th>Qty</th> <th>Price each</th> <th>Days Left</th> <th>Price total</th> <th>Links</th> </tr>"; $q=$db->query("SELECT cm.*, u.* FROM crystalmarket cm LEFT JOIN users u ON u.userid=cm.cmADDER ORDER BY cmPRICE/cmQTY ASC"); while($r=$db->fetch_row($q)) { if($r['cmADDER'] == $userid) { $link = "[url='cmarket.php?action=remove&ID={$r[']Remove[/url]"; } else { $link = "[url='cmarket.php?action=buy&ID={$r[']Buy[/url]"; } $each= (int) $r['cmPRICE'] / $r['cmQTY']; print "\n<tr> <td>[url='viewuser.php?u={$r[']{$r['username']}[/url] [{$r['userid']}]</td> <td>{$r['cmQTY']}</td> <td> \$" . number_format($each)."</td> <td>{$r['cmDAYS']} Days.</td> <td>\$".number_format($r['cmPRICE'])."</td> <td>[$link]</td> </tr>"; } print "</table>"; } function crystal_remove() { global $db,$ir,$c,$userid,$h; $q=$db->query("SELECT * FROM crystalmarket WHERE cmID={$_GET['ID']} AND cmADDER=$userid"); if(!$db->num_rows($q)) { print "Error, either these crystals do not exist, or you are not the owner. [url='cmarket.php']> Back[/url]"; $h->endpage(); exit; } $r=$db->fetch_row($q); $db->query("UPDATE users SET crystals=crystals+{$r['cmQTY']} where userid=$userid"); $db->query("DELETE FROM crystalmarket WHERE cmID={$_GET['ID']}"); print "Crystals removed from market! [url='cmarket.php']> Back[/url]"; } function crystal_buy() { global $db,$ir,$c,$userid,$h; $q=$db->query("SELECT * FROM crystalmarket cm WHERE cmID={$_GET['ID']}"); if(!$db->num_rows($q)) { print "Error, either these crystals do not exist, or they have already been bought. [url='cmarket.php']> Back[/url]"; $h->endpage(); exit; } $r=$db->fetch_row($q); if($r['cmPRICE'] > $ir['money']) { print "Error, you do not have the funds to buy these crystals. [url='cmarket.php']> Back[/url]"; $h->endpage(); exit; } $db->query("UPDATE users SET crystals=crystals+{$r['cmQTY']} where userid=$userid"); $db->query("DELETE FROM crystalmarket WHERE cmID={$_GET['ID']}"); $db->query("UPDATE users SET money=money-{$r['cmPRICE']} where userid=$userid"); $db->query("UPDATE users SET money=money+{$r['cmPRICE']} where userid={$r['cmADDER']}"); event_add($r['cmADDER'],"[url='viewuser.php?u=$userid']{$ir['username']}[/url] bought your {$r['cmQTY']} crystals from the market for \$".number_format($r['cmPRICE']).".",$c); print "You bought the {$r['cmQTY']} crystals from the market for \$".number_format($r['cmPRICE'])."."; } function crystal_add() { global $db,$ir,$c,$userid,$h; $_POST['amnt'] = abs((int) $_POST['amnt']); $_POST['price'] = abs((int) $_POST['price']); $_POST['days'] = abs(intval($_POST['days'])); if($_POST['amnt']) { if($_POST['amnt'] > $ir['crystals']) { die ("You are trying to add more crystals to the market than you have."); } if(!in_array($_POST['days'], array(1,5,10))) { echo 'Amount of days is invalid!'; $h->endpage(); exit; } $b=$db->query("SELECT * FROM crystalmarket WHERE cmADDER=$userid"); if ($db->num_rows($b) > 2) { die("<center>You Are Only Allowed 3 Crystal Sales At A Time [url='cmarket.php?action=add'] Back[/url]"); } $tp=$_POST['amnt']*$_POST['price']; $db->query("INSERT INTO crystalmarket VALUES('',{$_POST['amnt']},$userid,$tp,{$_POST['days']})"); $db->query("UPDATE users SET crystals=crystals-{$_POST['amnt']} WHERE userid=$userid"); print "Crystals added to market! [url='cmarket.php']> Back[/url]"; } else { print "[b]Adding a listing...[/b] You have [b]{$ir['crystals']}[/b] crystal(s) that you can add to the market.<form action='cmarket.php?action=add' method='post'><table width=50% border=2><tr> <td>Crystals:</td> <td><input type='text' name='amnt' value='{$ir['crystals']}' /></td></tr><tr> <td>Price Each:</td> <td><input type='text' name='price' value='200' /></td></tr><tr> <td>Days:</td> <td><select type='dropdown' name='days' value='{$ir['cmDAYS']}' />> <option value='1'>1 <option value='5'>5 <option value='10'>10</select> </tr> <td colspan=2 align=center><input type='submit' value='Add To Market' /></tr></table></form>"; } } $h->endpage(); ?>
  22. what it dose it when you add crystals you choose 1 5 10 days after they days are up it returnes the crystals and deletes from market also i have added a way they can only add 3 crystal sales at a time Replace cmarket.php with this <?php include "globals.php"; print "<h3>Crystal Market</h3>"; switch($_GET['action']) { case "buy": crystal_buy(); break; case "remove": crystal_remove(); break; case "add": crystal_add(); break; default: cmarket_index(); break; } function cmarket_index() { global $db,$ir,$c,$userid,$h; print "[url='cmarket.php?action=add']> Add A Listing[/url] Viewing all listings... <table width=75% cellspacing=1 class='table'> <tr style='background:gray'> <th>Adder</th> <th>Qty</th> <th>Price each</th> <th>Days Left</th> <th>Price total</th> <th>Links</th> </tr>"; $q=$db->query("SELECT cm.*, u.* FROM crystalmarket cm LEFT JOIN users u ON u.userid=cm.cmADDER ORDER BY cmPRICE/cmQTY ASC"); while($r=$db->fetch_row($q)) { if($r['cmADDER'] == $userid) { $link = "[url='cmarket.php?action=remove&ID={$r[']Remove[/url]"; } else { $link = "[url='cmarket.php?action=buy&ID={$r[']Buy[/url]"; } $each= (int) $r['cmPRICE'] / $r['cmQTY']; print "\n<tr> <td>[url='viewuser.php?u={$r[']{$r['username']}[/url] [{$r['userid']}]</td> <td>{$r['cmQTY']}</td> <td> \$" . number_format($each)."</td> <td>{$r['cmDAYS']} Days.</td> <td>\$".number_format($r['cmPRICE'])."</td> <td>[$link]</td> </tr>"; } print "</table>"; } function crystal_remove() { global $db,$ir,$c,$userid,$h; $q=$db->query("SELECT * FROM crystalmarket WHERE cmID={$_GET['ID']} AND cmADDER=$userid"); if(!$db->num_rows($q)) { print "Error, either these crystals do not exist, or you are not the owner. [url='cmarket.php']> Back[/url]"; $h->endpage(); exit; } $r=$db->fetch_row($q); $db->query("UPDATE users SET crystals=crystals+{$r['cmQTY']} where userid=$userid"); $db->query("DELETE FROM crystalmarket WHERE cmID={$_GET['ID']}"); print "Crystals removed from market! [url='cmarket.php']> Back[/url]"; } function crystal_buy() { global $db,$ir,$c,$userid,$h; $q=$db->query("SELECT * FROM crystalmarket cm WHERE cmID={$_GET['ID']}"); if(!$db->num_rows($q)) { print "Error, either these crystals do not exist, or they have already been bought. [url='cmarket.php']> Back[/url]"; $h->endpage(); exit; } $r=$db->fetch_row($q); if($r['cmPRICE'] > $ir['money']) { print "Error, you do not have the funds to buy these crystals. [url='cmarket.php']> Back[/url]"; $h->endpage(); exit; } $db->query("UPDATE users SET crystals=crystals+{$r['cmQTY']} where userid=$userid"); $db->query("DELETE FROM crystalmarket WHERE cmID={$_GET['ID']}"); $db->query("UPDATE users SET money=money-{$r['cmPRICE']} where userid=$userid"); $db->query("UPDATE users SET money=money+{$r['cmPRICE']} where userid={$r['cmADDER']}"); event_add($r['cmADDER'],"[url='viewuser.php?u=$userid']{$ir['username']}[/url] bought your {$r['cmQTY']} crystals from the market for \$".number_format($r['cmPRICE']).".",$c); print "You bought the {$r['cmQTY']} crystals from the market for \$".number_format($r['cmPRICE'])."."; } function crystal_add() { global $db,$ir,$c,$userid,$h; $_POST['amnt'] = abs((int) $_POST['amnt']); $_POST['price'] = abs((int) $_POST['price']); if($_POST['amnt']) { if($_POST['amnt'] > $ir['crystals']) { die ("You are trying to add more crystals to the market than you have."); } $b=$db->query("SELECT * FROM crystalmarket WHERE cmADDER=$userid"); if ($db->num_rows($b) > 2) { die("<center>You Are Only Allowed 3 Crystal Sales At A Time [url='cmarket.php?action=add'] Back[/url]"); } $tp=$_POST['amnt']*$_POST['price']; $db->query("INSERT INTO crystalmarket VALUES('',{$_POST['amnt']},$userid,$tp,{$_POST['days']})"); $db->query("UPDATE users SET crystals=crystals-{$_POST['amnt']} WHERE userid=$userid"); print "Crystals added to market! [url='cmarket.php']> Back[/url]"; } else { print "[b]Adding a listing...[/b] You have [b]{$ir['crystals']}[/b] crystal(s) that you can add to the market.<form action='cmarket.php?action=add' method='post'><table width=50% border=2><tr> <td>Crystals:</td> <td><input type='text' name='amnt' value='{$ir['crystals']}' /></td></tr><tr> <td>Price Each:</td> <td><input type='text' name='price' value='200' /></td></tr><tr> <td>Days:</td> <td><select type='dropdown' name='days' value='{$ir['cmDAYS']}' />> <option value='1'>1 <option value='5'>5 <option value='10'>10</select> </tr> <td colspan=2 align=center><input type='submit' value='Add To Market' /></tr></table></form>"; } } $h->endpage(); ?>   add the to your cron_hour.php $db->query("UPDATE crystalmarket SET cmDAYS = cmDAYS - 1 WHERE cmDAYS > 0"); if($r['cmDAYS'] == 0) { $q=$db->query("SELECT cm.*, u.* FROM crystalmarket cm LEFT JOIN users u ON u.userid=cm.cmADDER ORDER BY cmPRICE/cmQTY ASC"); while($r=$db->fetch_row($q)) { $q=$db->query("SELECT * FROM crystalmarket WHERE cmID={$r['cmID']} AND cmADDER={$r['userid']}"); $r=$db->fetch_row($q); $db->query("UPDATE users SET crystals=crystals+{$r['cmQTY']} WHERE userid={$r['cmADDER']}"); $db->query("DELETE FROM crystalmarket WHERE cmID={$r['cmID']}"); } }   add this to your DB SQL ALTER TABLE `crystalmarket` ADD `cmDAYS` INT( 11 ) NOT NULL DEFAULT '1';   Add Your Done. any bugs message me but has been tested adding the itemmarket 1 soon
  23. ok guys iam new at coding so don't all slag me and say ooo thats wrong and ooo you have done that the wrong way i read the forums i new what you guys are like and can sometimes be a bit harsh but anywayz its my first mod made from scratch so don't judge me to badly please. Replace helptutorial.php with this <?php include "globals.php"; $q=mysql_query("SELECT * FROM helppage WHERE pageid=1", $c); while($r=mysql_fetch_array($q)) { print "<h3><center>{$r['pagetitle']}</h3> <hr /> {$r['helptext']} </center>"; } ?>   make new page call it helppage.php <?php include "sglobals.php"; if($ir['user_level'] > 2) { die("403"); } if ($_POST['submit']) { $db->query("UPDATE helppage SET pagetitle='{$_POST['pagetitle']}', helptext='{$_POST['helptext']}' WHERE pageid='1'"); print "Helppage Updated [url='helppage.php']Go Back[/url]"; } else { $q=mysql_query("SELECT * FROM helppage WHERE pageid=1", $c); while($r=mysql_fetch_array($q)) { print "<h3>Help Edit</h3><hr /> <form action='helppage.php' method='post'> <input type='hidden' name='submit' value='helppage' /> Header: <input type='text' name='pagetitle' value='{$r['pagetitle']}' /> Help Text: <textarea rows='7' cols='50' name='helptext'>{$r['helptext']}</textarea> <input type='submit' value='Update' /></form>"; print "<center><font color=red><h3>HTML Allowed</h3></font></center>"; } } ?>   Your Sql not really good with them but i will give it a try CREATE TABLE IF NOT EXISTS `helppage` ( `pageid` int(11) NOT NULL auto_increment, `pagetitle` varchar(255) NOT NULL default '', `pagetext` text NOT NULL default'', PRIMARY KEY (`pageid`) );   add to SQL INSERT INTO helppage VALUES('1','Game Tutorial','enter here'); add your like to smenu [url='helppage.php']Edit Page Tutorial[/url]   and your done. hope u like it
  24. Re: [mccodes]Updated Education Guys here is a staff course to easily add new courses to your new script. Staff_courses.php <?php include "sglobals.php"; if($ir['user_level'] > 2) { die("403"); } //This contains course stuffs switch($_GET['action']) { case "addcourse": addcourse(); break; case "editcourse": editcourse(); break; case "delcourse": delcourse(); break; default: print "Error: This script requires an action."; break; } function addcourse() { global $db, $ir, $c, $h, $userid; $cost=abs((int) $_POST['cost']); $energy=abs((int) $_POST['energy']); $days=abs((int) $_POST['days']); $str=abs((int) $_POST['str']); $agil=abs((int) $_POST['agil']); $gua=abs((int) $_POST['gua']); $lab=abs((int) $_POST['lab']); $iq=abs((int) $_POST['iq']); if($_POST['name'] && $_POST['type'] && $_POST['desc'] && $cost && $days) { $db->query("INSERT INTO courses VALUES('', '{$_POST['name']}','{$_POST['type']}', '{$_POST['desc']}', '$cost', '$energy', '$days', '$str', '$gua', '$lab', '$agil', '$iq','{$_POST['item']}')"); print "Course {$_POST['name']} added."; stafflog_add("Added course {$_POST['name']}"); } else { print "<h3>Add Course</h3><hr /> <table class='table' width='50%'> <tr> <form action='staff_courses.php?action=addcourse' method='post'> <td>Name:</td><td><input type='text' name='name' /></td> </tr> <tr> <td>Description:</td><td><input type='text' name='desc' /></td> </tr> <tr> <td>Type:</td><td><select type='dropdown' name='type' /> <option value='Intelligence'>Intelligence <option value='Manual Labour'>Manual Labour <option value='Fitness'>Fitness <option value='Miscellaneous'>Miscellaneous</select></td> </tr> <tr> <td>Item:</td><td>".item_dropdown($c,"item")."</td> </tr> <tr> <td>Cost (Money):</td><td><input type='text' name='cost' /></td> </tr> <tr> <td>Cost (Energy):</td><td><input type='text' name='energy' /></td> </tr> <tr> <td>Length (Days):</td><td><input type='text' name='days' /></td> </tr> <tr> <td>Strength Gain:</td><td><input type='text' name='str' /></td> </tr> <tr> <td>Agility Gain:</td><td><input type='text' name='agil' /></td> </tr> <tr> <td>Guard Gain:</td><td><input type='text' name='gua' /></td> </tr> <tr> <td>Labour Gain:</td><td><input type='text' name='lab' /></td> </tr> <tr> <td>IQ Gain:</td><td><input type='text' name='iq' /></td> </tr> <tr> <td colspan=2 align=center><input type='submit' value='Add Course' /></form></td> </tr> </table>"; } } function editcourse() { global $db, $ir, $c, $h, $userid; switch($_POST['step']) { case "2": $cost=abs((int) $_POST['cost']); $energy=abs((int) $_POST['energy']); $days=abs((int) $_POST['days']); $str=abs((int) $_POST['str']); $agil=abs((int) $_POST['agil']); $gua=abs((int) $_POST['gua']); $lab=abs((int) $_POST['lab']); $iq=abs((int) $_POST['iq']); $name=$_POST['name']; $db->query("UPDATE courses SET crNAME='$name', crCAT='{$_POST['type']}', crDESC='{$_POST['desc']}', crCOST=$cost, crENERGY=$energy, crDAYS=$days, crSTR=$str, crGUARD=$gua, crLABOUR=$lab, crAGIL=$agil, crIQ=$iq, crITEM='{$_POST['item']}' WHERE crID={$_POST['id']}"); print "Course $name was edited successfully."; stafflog_add("Edited course $name"); break; case "1": $q=$db->query("SELECT * FROM courses WHERE crID={$_POST['course']}"); $old=$db->fetch_row($q); print "<h3>Editing a Course</h3><hr /> <table class=table width=50%> <form action='staff_courses.php?action=editcourse' method='post'> <input type='hidden' name='step' value='2' /> <input type='hidden' name='id' value='{$_POST['course']}' /> <td>Name:</td><td><input type='text' name='name' value='{$old['crNAME']}' /></td> </tr> <tr> <td>Description:</td><td><input type='text' name='desc' value='{$old['crDESC']}' /></td> </tr> <tr> <td>Type:</td><td><select type='dropdown' name='type' value='{$old['crCAT']}' /> <option value='Intelligence'>Intelligence <option value='Manual Labour'>Manual Labour <option value='Fitness'>Fitness <option value='Miscellaneous'>Miscellaneous</select></td> </tr> <tr> <td>Item:</td><td>".item_dropdown($c,"item")."</td> </tr> <tr> <td>Cost (Money):</td><td><input type='text' name='cost' value='{$old['crCOST']}' /></td> </tr> <tr> <td>Cost (Energy):</td><td><input type='text' name='energy' value='{$old['crENERGY']}' /></td> </tr> <tr> <td>Length (Days):</td><td><input type='text' name='days' value='{$old['crDAYS']}' /></td> </tr> <tr> <td>Strength Gain:</td><td><input type='text' name='str' value='{$old['crSTR']}' /></td> </tr> <tr> <td>Agility Gain:</td><td><input type='text' name='agil' value='{$old['crAGIL']}' /></td> </tr> <tr> <td>Guard Gain:</td><td><input type='text' name='gua' value='{$old['crGUARD']}' /></td> </tr> <tr> <td>Labour Gain:</td><td><input type='text' name='lab' value='{$old['crLABOUR']}' /></td> </tr> <tr> <td>IQ Gain:</td><td><input type='text' name='iq' value='{$old['crIQ']}' /></td> </tr> <tr> <td colspan=2 align=center><input type='submit' value='Edit Course' /></form></td> </tr> </table>"; break; default: print "<h3>Editing a Course</h3><hr /> <form action='staff_courses.php?action=editcourse' method='post'> <input type='hidden' name='step' value='1' /> Course: ".course_dropdown($c, "course")." <input type='submit' value='Edit Course' /></form>"; break; } } function delcourse() { global $db,$ir,$c,$h,$userid; if($_POST['course']) { $q=$db->query("SELECT * FROM courses WHERE crID={$_POST['course']}"); $old=$db->fetch_row($q); $db->query("UPDATE users SET course=0, cdays=0 WHERE course={$_POST['course']}"); $db->query("DELETE FROM courses WHERE crID={$_POST['course']}"); print "Course {$old['crNAME']} deleted."; stafflog_add("Deleted course {$old['crNAME']}"); } else { print "<h3>Deleting a Course</h3><hr /> <form action='staff_courses.php?action=delcourse' method='post'> Course: ".course_dropdown($c, "course")." <input type='submit' value='Delete Course' /></form>"; } } function report_clear() { global $db,$ir,$c,$h,$userid; if($ir['user_level'] > 3) { die("403"); } $_GET['ID'] = abs((int) $_GET['ID']); stafflog_add("Cleared player report ID {$_GET['ID']}"); $db->query("DELETE FROM preports WHERE prID={$_GET['ID']}"); print "Report cleared and deleted! [url='staff_users.php?action=reportsview']> Back[/url]"; } $h->endpage(); ?>   Also If u have the normal items table add this INSERT INTO `items`VALUES ( '0', '0', 'None', '', '0', '0', '0', '0', '', '0', '', '0', '', '0', '0',);   this item is for the courses if you select none they wont get anything after the course if there is an easier way of setting it to none please help out iam really new to coding thanks     Souiassassin
  25. Re: [REVIEW] Dark Streets Is Almost Complete Please Review fixed thanks is there any comments about the game
×
×
  • Create New...