-
Posts
2,667 -
Joined
-
Last visited
-
Days Won
75
Content Type
Profiles
Forums
Events
Everything posted by Uridium
-
Re: [NOTAMOD]Free Crypting[NOTAMOD] this site will do exaclty the same http://www.rightscripts.com/phpencode/index.php
-
[MMCODE V2] Set Sell Price of houses after they are Purchased...
Uridium replied to Uridium's topic in Free Modifications
Re: [MMCODE V2] Set Sell Price of houses after they are Purchased... for those who are seeing the message that their houses are being sold for $0 then alter this $db->query("UPDATE users SET money=money+'{$np['hSELLPRICE']}',will=150,maxwill=150 WHERE userid=$userid",$c); print "You sold your {$np['hNAME']} for \$$j".money_formatter($r['hSELLPRICE'],'')." Minus Lawyer fees and went back to your shed."; to this $db->query("UPDATE users SET money=money+'{$np['hSELLPRICE']}',will=150,maxwill=150 WHERE userid=$userid",$c); print "You sold your {$np['hNAME']} for \$$j".money_formatter($np['hSELLPRICE'],'')." Minus Lawyer fees and went back to your shed."; -
Re: Lost my crons(v2) just goto a torrent site your bound to get a free one there ( NOT THAT I AGREE TO THEFT ) or google one :) Is bound to get a few Minus marks for my post now oops lol
-
Re: New Houses Mod [Mccodes V2] I made a small booboo on the above script to remove from market so goto the function that removes from market and find this line.. mysql_query(sprintf("UPDATE `owned_houses` SET `uhouseRent` = '0', `uhouseRTime` = '0', `uhouseTenant` = '0' WHERE `uhouseId` = '2'", $_GET['id'])); and replace with mysql_query(sprintf("UPDATE `owned_houses` SET `uhouseRent` = '0', `uhouseRTime` = '0', `uhouseTenant` = '0' WHERE `uhouseId` = '%u'", $_GET['id'])); Sorry about that
-
Re: New Houses Mod [Mccodes V2] I was thinking about adding a per month price increase for house rentals as it would make this mod a lot more productive
-
Re: Help Please I never like reading about learning things cos i could never take it all in. what i did find though was looking at a small script and deliberatley make an error in it to find what the outcome would be, Obviously an error message was displayed but i learnt that certain error messages reflected on certain mistakes i made so i knew instantly how to fix an error for the message displayed.. Do it in bite size chunks dont take on a big script get used to what statements do also having a decent text editor is a great idea like Notepad++ which is free and displays PHP in a colourful way so its easier to spot mistakes rather than using the rudamentry notepad that comes with windows..
-
Re: New Houses Mod [Mccodes V2] * FOOT NOTE * when editing a rented property you will need to Remove it from the rented list first then edit it. I didnt want people thinking you could edit the Rentals whilst others were still able to rent :)
-
Re: New Houses Mod [Mccodes V2] Just a small Update to Richards mod this upgrade will allow users to remove their house from being rented and will also allow them to edit the rental settings.. houses.php <?php include_once('globals.php'); echo '<p class="heading">Your Houses</p>'; switch ($_GET['page']) { case 'move': move_house(); break; case 'move_out': move_out(); break; case 'estate': estate_agent(); break; case 'sell': sell_house(); break; case 'rentals': rental_market(); break; case 'rent': rent_house(); break; case 'removestart': remove_from_market_start(); break; case 'removal': remove_from_market_end(); break; case 'upgrade': upgrade_house(); break; default: houses_index(); break; } function houses_index() { global $ir; $houses = mysql_query(sprintf("SELECT * FROM `owned_houses` LEFT JOIN `houses` ON (`hID` = `uhouseHouse`) LEFT JOIN `users` ON (`userid` = `uhouseOwner`) WHERE (`uhouseOwner` = '%u' || `uhouseTenant` = '%u') AND `uhouseId` != '%d'", $ir['userid'], $ir['userid'], $ir['house'])); echo '<table width="600"> <tr> <td width="50%" align="left">[url="houses.php?page=estate"]Estate agent[/url]</td> <td width="50%" align="center">[url="houses.php?page=rentals"]Rent a house[/url]</td> </tr> </table> '; if($ir['house']) { $fetch = mysql_query(sprintf("SELECT * FROM `owned_houses` LEFT JOIN `houses` ON (`hID` = `uhouseHouse`) WHERE (`uhouseId` = '%u')", $ir['house'])); $h = mysql_fetch_assoc($fetch); echo '[b]Current house:[/b] <table width="300" class="table"> <tr> <th width="50%">Current house</th> <th width="50%">Move out</th> </tr> <tr> <td>'.stripslashes($h['hNAME']).'</td> <td>[url="houses.php?page=move_out"]Move out[/url]</td> </tr> </table> '; } echo '<table width="600" class="table"> <tr> <th width="25%">House name</th> <th width="25%">Owner</th> <th width="25%">Mood value</th> <th width="25%">Manage</th> <th width="25%">Remove</th> </tr>'; if(!mysql_num_rows($houses)) { echo '<tr> <td colspan="5">You have no houses at this time, purchase one at the estate agent\'s.</td> </tr>'; } while($r = mysql_fetch_assoc($houses)) { echo '<tr> <td>'.stripslashes($r['hNAME']).'</td> <td>[url="viewuser.php?u='.$r['userid'].'"]'.stripslashes($r['username']).'[/url]</td> <td>'.number_format($r['uhouseMood']).' mood bar</td> <td>[url="houses.php?page=move&id='.$r['uhouseId'].'"]Move in[/url] [url="houses.php?page=sell&id='.$r['uhouseId'].'"]Sell house[/url] [url="houses.php?page=rent&id='.$r['uhouseId'].'"]Rent house[/url] [url="houses.php?page=upgrade&id='.$r['uhouseId'].'"]Add upgrades[/url]</td> <td>[url="houses.php?page=removal&id='.$r['uhouseId'].'"]Remove '.($r['hNAME']).'[/url]</td> </tr>'; } echo '</table>'; } function move_house() { global $ir; $fetch = mysql_query(sprintf("SELECT * FROM `owned_houses` LEFT JOIN `houses` ON (`hID` = `uhouseHouse`) LEFT JOIN `users` ON (`userid` = `uhouseOwner`) WHERE (`uhouseId` = '%u')", abs((int) $_GET['id']))); if(!isset($_GET['id'])) { echo 'You did not select a house to move in to.'; } else if(!mysql_num_rows($fetch)) { echo 'You cannot move into a non-existant house.'; } else { $r = mysql_fetch_assoc($fetch); if($r['uhouseOwner'] != $ir['userid'] AND $r['uhouseTenant'] != $ir['userid']) { echo 'You are not permitted to move into this house.'; } else if($r['uhouseRTime'] AND $r['uhouseOwner'] == $ir['userid']) { echo 'You cannot move into a house while it is being rented to another member.'; } else { mysql_query(sprintf("UPDATE `users` SET `house` = '%d', `maxwill` = '%d' WHERE (`userid` = '%u')", abs((int) $_GET['id']), $r['uhouseMood'], $ir['userid'])); echo 'You have moved into the '.stripslashes($r['hNAME']).', You now have a maximum mood bar of '.number_format($r['uhouseMood']).'.'; } } } function move_out() { global $ir; $fetch = mysql_query(sprintf("SELECT * FROM `owned_houses` LEFT JOIN `houses` ON (`hID` = `uhouseHouse`) LEFT JOIN `users` ON (`userid` = `uhouseOwner`) WHERE (`uhouseId` = '%u')", $ir['house'])); if(!mysql_num_rows($fetch)) { echo 'You cannot move out of a non-existant house.'; } else { $r = mysql_fetch_assoc($fetch); if($r['uhouseOwner'] != $ir['userid'] AND $r['uhouseTenant'] != $ir['userid']) { echo 'You are not permitted to move out of this house.'; } else { mysql_query(sprintf("UPDATE `users` SET `house` = '0', `maxwill` = '100' WHERE (`userid` = '%u')", $ir['userid'])); echo 'You have moved out of the '.stripslashes($r['hNAME']).', You now have a maximum mood bar of 100.'; } } } function sell_house() { global $ir; $fetch = mysql_query(sprintf("SELECT * FROM `owned_houses` LEFT JOIN `houses` ON (`hID` = `uhouseHouse`) LEFT JOIN `users` ON (`userid` = `uhouseOwner`) WHERE (`uhouseOwner` = '%u') AND (`uhouseId` = '%u')", $ir['userid'], abs((int) $_GET['id']))); if(!isset($_GET['id'])) { echo 'You did not select a house to sell.'; } else if(!mysql_num_rows($fetch)) { echo 'You cannot attempt to sell a non-existant house.'; } else { $r = mysql_fetch_assoc($fetch); if($r['uhouseOwner'] != $ir['userid']) { echo 'You do not own this house, so don\'t attempt to sell it.'; } else if($r['uhouseTenant']) { echo 'You cannot sell a house while it is being rented to another member.'; } else { mysql_query(sprintf("UPDATE `users` SET `money` = `money` + '%d' WHERE (`userid` = '%u')", $r['houseCost'], $ir['userid'])); mysql_query(sprintf("DELETE FROM `owned_houses` WHERE (`uhouseId` = '%u')", abs((int) $_GET['id']))); echo 'You have sold the '.stripslashes($r['hNAME']).' for a total of $'.number_format($r['hPRICE']).'.'; } } } function estate_agent() { global $ir; if(isset($_GET['id'])) { $house = mysql_query(sprintf("SELECT * FROM `houses` WHERE (`hID` = '%u')", abs((int) $_GET['id']))); $r = mysql_fetch_assoc($house); if(!mysql_num_rows($house)) { echo 'You cannot attempt to purchase a non-existant house.'; } else if($ir['money'] < $r['hPRICE']) { echo 'You cannot afford to purchase this house right now, come back another time.'; } else { mysql_query(sprintf("UPDATE `users` SET `money` = `money` - '%d' WHERE (`userid` = '%u')", $r['hPRICE'], $ir['userid'])); mysql_query(sprintf("INSERT INTO `owned_houses` (`uhouseId`, `uhouseOwner`, `uhouseHouse`, `uhouseMood`) VALUES ('NULL','%u', '%d', '%d')", $ir['userid'], $r['hID'], $r['hWILL'])); echo 'You have purchased the '.stripslashes($r['hNAME']).' for a total of $'.number_format($r['houseCost']).'!'; } } else { $houses = mysql_query(sprintf("SELECT * FROM `houses` ORDER BY `hWILL` ASC")); echo '<table width="600" class="table"> <tr> <th>House name</th> <th>Mood value</th> <th>Cost</th> </tr>'; while($r = mysql_fetch_assoc($houses)) { echo '<tr> <td>[url="houses.php?page=estate&id='.$r['hID'].'"]'.stripslashes($r['hNAME']).'[/url]</td> <td>'.number_format($r['hWILL']).' mood bar</td> <td>$'.number_format($r['hPRICE']).'</td> </tr>'; } print '</table>'; } } function rental_market() { global $ir; if(isset($_GET['id'])) { $house = mysql_query(sprintf("SELECT * FROM `owned_houses` LEFT JOIN `houses` ON (`hID` = `uhouseHouse`) LEFT JOIN `users` ON (`userid` = `uhouseOwner`) WHERE (`uhouseId` = '%u')", abs((int) $_GET['id']))); $r = mysql_fetch_assoc($house); if(!mysql_num_rows($house)) { echo 'You cannot rent a house that does not exist.'; } else if($r['uhouseOwner'] == $ir['userid']) { echo 'You own this house at this time, You cannot rent it aswell.'; } else { mysql_query(sprintf("UPDATE `owned_houses` SET `uhouseTenant` = '%d' WHERE (`uhouseId` = '%u')", $ir['userid'], abs((int) $_GET['id']))); echo 'You are now renting the '.stripslashes($r['hNAME']).' for a total of $'.number_format($r['uhouseRent']).' each night!'; } } else { $houses = mysql_query(sprintf("SELECT * FROM `owned_houses` LEFT JOIN `houses` ON (`hID` = `uhouseHouse`) LEFT JOIN `users` ON (`userid` = `uhouseOwner`) WHERE `uhouseTenant` = '0' AND `uhouseRent` > '0' ORDER BY `uhouseRent` ASC")); echo '<table width="600" class="table"> <tr> <th>House name</th> <th>Owner</th> <th>Mood value</th> <th>Cost each night</th> <th>Rental time</th> <th>Manage</th> <th>Remove</th> </tr>'; while($r = mysql_fetch_assoc($houses)) { echo '<tr> <td>'.stripslashes($r['hNAME']).'</td> <td>[url="userprofile.php?id='.$r['userid'].'"]'.stripslashes($r['username']).'[/url]</td> <td>'.number_format($r['uhouseMood']).' mood bar</td> <td>$'.number_format($r['uhouseRent']).'</td> <td>'.number_format($r['uhouseRTime']).' nights</td> <td>[url="houses.php?page=rentals&id='.$r['uhouseId'].'"]Rent house[/url]</td> <td>[url="houses.php?page=removal&id='.$r['uhouseId'].'"]Remove '.($r['hNAME']).'[/url]</td> </tr>'; } print '</table>'; } } function rent_house() { global $ir; $fetch = mysql_query(sprintf("SELECT * FROM `owned_houses` LEFT JOIN `houses` ON (`hID` = `uhouseHouse`) LEFT JOIN `users` ON (`userid` = `uhouseOwner`) WHERE (`uhouseOwner` = '%u') AND (`uhouseId` = '%u')", $ir['userid'], abs((int) $_GET['id']))); if(!isset($_GET['id'])) { echo 'You did not select a house to rent out to members.'; } else if(!mysql_num_rows($fetch)) { echo 'You cannot attempt to rent out a non-existant house.'; } else { $r = mysql_fetch_assoc($fetch); if($r['uhouseOwner'] != $ir['userid']) { echo 'You do not own this house, so don\'t attempt to rent it out to people.'; } else if($r['uhouseTenant']) { echo 'You cannot rent out a house while it is being rented to another member.'; } else { if(isset($_POST['time']) AND isset($_POST['cost'])) { mysql_query(sprintf("UPDATE `owned_houses` SET `uhouseRent` = '%d', `uhouseRTime` = '%d' WHERE (`uhouseId` = '%u')", abs((int) $_POST['cost']), abs((int) $_POST['time']), abs((int) $_GET['id']))); echo 'You have added the '.stripslashes($r['hNAME']).' the the rental market at a cost of $'.number_format($_POST['cost']).' per night.'; } else { echo '<form action="houses.php?page=rent&id='.$_GET['id'].'" method="post"> <table width="600"> <tr> <td>[b]Amount of nights:[/b]</td> <td><input type="text" name="time" value="30" /></td> </tr> <tr> <td>[b]Cost per nights:[/b]</td> <td><input type="text" name="cost" value="250" /></td> </tr> <tr> <td colspan="2" align="center"><input type="submit" value="Submit rental" /></td> </tr> </table> </form>'; } } } } function remove_from_market_end() { global $db,$ir,$c,$h,$userid; $fetch = mysql_query(sprintf("SELECT * FROM `owned_houses` LEFT JOIN `houses` ON (`hID` = `uhouseHouse`) LEFT JOIN `users` ON (`userid` = `uhouseOwner`) WHERE (`uhouseOwner` = '%u') AND (`uhouseId` = '%u')", $ir['userid'], abs((int) $_GET['id']))); if(!isset($_GET['id'])) { echo 'You did not select a house to remove from the market.'; } else if(!mysql_num_rows($fetch)) { echo 'You cannot attempt to rent out a non-existant house.'; } else { $r = mysql_fetch_assoc($fetch); if($r['uhouseOwner'] != $ir['userid']) { echo 'You do not own this house, so don\'t attempt to rent it out to people.'; } else if($r['uhouseTenant']) { echo 'You cannot remove a rented house whilst it\'s being lived in by another member.'; } //if(isset($_POST['time']) AND isset($_POST['cost'])) { mysql_query(sprintf("UPDATE `owned_houses` SET `uhouseRent` = '0', `uhouseRTime` = '0', `uhouseTenant` = '0' WHERE `uhouseId` = '2'", $_GET['id'])); echo '<h1> '.stripslashes($r['hNAME']).' Will no Longer Be classed as a Rented Property</h1> [url="houses.php>["]> RETURN << ][/url]'; } //else { } } } function upgrade_house() { global $ir; if(!isset($_POST['id'])) { if(isset($_GET['id'])) { echo '<form action="houses.php?page=upgrade&id='.$_GET['id'].'" method="post" name="upgrades"> <table class="table" width="600"> <tr> <th width="45%">Upgrade name</th> <th width="25%">Mood gain</th> <th width="25%">Cost</th> <th width="5%"></th> </tr>'; $fetch = mysql_query("SELECT * FROM `house_upgrades` ORDER BY `upgradeMood` ASC"); while ($r = mysql_fetch_assoc($fetch)) { echo '<tr> <td>'.stripslashes($r['upgradeName']).'</td> <td>'.number_format($r['upgradeMood']).' mood</td> <td>$'.number_format($r['upgradeCost']).'</td> <td><input type="radio" name="id" value="'.$r['upgradeId'].'" onClick="document.upgrades.submit();" /></td> </tr>'; } echo '</table>'; } else { echo 'You did not select a house to add upgrades to.'; } } else { $upgrade = mysql_query(sprintf("SELECT * FROM `house_upgrades` WHERE `upgradeId` = '%u'", abs((int) $_POST['id']))); if(!mysql_num_rows($upgrade)) { echo 'This upgrade does not exist at this time, if this problem continues report it to staff.'; } else if(!isset($_GET['id'])) { echo 'You did not select a house to add upgrades to.'; } else { $house = mysql_query(sprintf("SELECT * FROM `owned_houses` LEFT JOIN `houses` ON (`hID` = `uhouseHouse`) LEFT JOIN `users` ON (`userid` = `uhouseOwner`) WHERE (`uhouseId` = '%u')", abs((int) $_GET['id']))); $h = mysql_fetch_assoc($house); $r = mysql_fetch_array($upgrade); if(!mysql_num_rows($house)) { echo 'You cannot add upgrades to a non-existant house.'; } else if($h['uhouseOwner'] != $ir['userid']) { echo 'You are not permitted to add upgrades to this house.'; } else if($ir['money'] < $r['upgradeCost']) { echo 'You do not have enough cash to purchase this upgrade right now.'; } else { $check = mysql_query(sprintf("SELECT * FROM `owned_upgrades` WHERE (`ownupHouse` = '%u') AND (`ownupUpgrade` = '%d')", abs((int) $_GET['id']), abs((int) $_POST['id']))); if(mysql_num_rows($check)) { echo 'This house has this upgrade at this time, it cannot be bought again.'; } else { mysql_query(sprintf("UPDATE `users` SET `money` = `money` - '%d' WHERE `userid` = '%u'", $r['upgradeCost'], $ir['userid'])); mysql_query(sprintf("UPDATE `owned_houses` SET `uhouseMood` = `uhouseMood` + '%d' WHERE `uhouseId` = '%u'", $r['upgradeMood'], abs((int) $_GET['id']))); mysql_query(sprintf("INSERT INTO `owned_upgrades` (`ownupId`, `ownupHouse`, `ownupUpgrade`) VALUES ('NULL','%u', '%d')", abs((int) $_GET['id']), abs((int) $_POST['id']))); echo 'You have purchased the '.stripslashes($r['upgradeName']).' for $'.number_format($r['upgradeCost']).'.'; } } } } } $h->endpage(); ?>
-
Re: viewuser Put up a screenie of your current Viewuser so we have an idea what that layouts like
-
This is quite useful for those that have the same url link on multiple files and want to change the name of the actual file name. example there are various files that can use the viewuser.php but if we changed the filename to say look_at_user.php then we would have to change every files so it matches the new link.. what this trick does is it lets you change the config.php file so every link for look_at_user.php is automatically updated on every file that calls for the file.. so for arguments sake we want to add a new staff.php name which we will call staff_new_name.php so open up config.php after the cron code add a , at the end and add $staff_file = 'staff_new_name' now open up mainmenu.php and under the <? add include "config.php"; and change the url for the staff link to if your using the echo statement echo "Staff Menu"; or this if your using the print statement print "Staff Menu "; change name of the file as well so it reflects to staff_new_name.php << this is just an example name obviously... repeat the procedure for all the new file names you want to create.
-
call this file imagesearch.php <?php include "globals.php"; ///////////////////////////// // Illusions 2009 image search // ///////////////////////////// echo '<form method="get" action="http://www.google.com/images" target="_blank"> <input type="text" name="q" size="31" maxlength="255" value="" /> <input type="submit" value="Search for images" /> </form> '; $h->endpage(); ?> Bang a link in your preferences,php pointnig to the above file and bobs yer uncle.. and fannys yer aunt ;) Whats it do: Type any image name into the Search bar and google will find it :)
-
Re: multiple houses with shared housing This part concerns me.. what if the owner of the highest house divorces them and the other person decides not to leave. ? or am i thinking to far in front.
-
Re: MainMenu Mod! NEW! What Modern-Empires means Bwerk is the version you posted above is for mcc v1 as V2 doesnt require the use of the mysql.php file anymore other things you may encounter are some silly error like CALL TO UNDEFINED FUNTION so when you see a global command add $db to it
-
Re: [mccode v2] Items Pic mod SMOKEY goto your phpymyadmin and select ITEMS from there count the number of tables..... Then goto your staff_items.php and count the amount of INSERT INTO queries there is they should both match if not then you will need to work out which table is missing from phpmyadmin or your php file.
-
[MCCODES V2] File Creator and Editor ingame
Uridium replied to Uridium's topic in Free Modifications
Re: [MCCODES V2] File Creator and Editor ingame There is no safe feature to this mod.. its only safe if one person uses it and that person is the game owner and doesnt tell anyone wat the files are called. -
[MCCODES V2] File Creator and Editor ingame
Uridium replied to Uridium's topic in Free Modifications
Re: [MCCODES V2] File Creator and Editor ingame as noted from above -
[MCCODES V2] File Creator and Editor ingame
Uridium replied to Uridium's topic in Free Modifications
Re: [MCCODES V2] File Creator and Editor ingame oO0 SECURITY NOTICE 0Oo PLEASE CHANGE THE NAMES OF BOTH FILES AND ANYLINKS THAT ARE IN THEM EVEN THE STAFF LINKS WILL NEED TO BE CHANGED This is purely so other users that see this script dont decide to randomly type illusions.php or filedata.php im aware both are setup only for admin access but a little more security wont harm it..... OOPS forgot to mention on script post also make a txt file called filedata.txt this is for the inview of the filedata.php file which will allow you to change the link of the file you want to edit to a new one so you dont have to keep uploading filedata.php all the time. -
Re: [mccode v2] Ignore User Mail Fixed it... new sql ALTER TABLE ignore ADD reason VARCHAR (255) NOT NULL Call this file ignore.php And your users can now place a reason why statement for each person the ignore, <?php /*----------------------------------------------------- -- Ignore User For MC Code V2 -- Free Mod -- [url]http://www.squangle.org[/url] -- By Tonka -- ignore.php -----------------------------------------------------*/ include "globals.php"; switch($_GET['action']) { case 'ignoreform': ignore_form(); break; case 'ignoresub': ignore_submit(); break; case 'unignore': unignore(); break; default; index(); break; } function index() { global $db,$userid; echo '<h3>Ignoring a user</h3> [url="'.$_SERVER['PHP_SELF'].'?action=ignoreform"]Add User To Be Ignored[/url] <table width="85%" cellspacing="1" class="table"> <th>User ID</th> <th>Username</th> <th>Remove?</th> <th>Reason</th> <th>Status</th>'; $sql = sprintf(("SELECT `id`, `blocked`, `reason` FROM `ignore` WHERE userid = %u"), $userid); $q = $db->query($sql); while($r=$db->fetch_row($q)) { $select = sprintf(("SELECT `username`, `laston` FROM `users` WHERE userid = %u"), $r['blocked']); $u2 = $db->query($select); $u=$db->fetch_row($u2); $username = $u['username']; $id = $r['id']; if($u['laston'] >= time()-15*60) { $on='<font color=green>[b]Online[/b]</font>'; } else { $on='<font color=red>[b]Offline[/b]</font>'; } echo '<tr><td>'; echo sprintf("%u", $r['blocked']); echo '</td><td>'; echo '<a href="viewuser.php?u='; echo sprintf("%u", $r['blocked']); echo '">'; echo $username; echo '</a>'; echo '</td><td>'; echo '<a href="'.$_SERVER['PHP_SELF'].'?action=unignore&id='; echo $id; echo '">Remove</a>'; echo '</td><td>'; echo $r['reason']; echo '</td><td>'; echo $on; echo '</td></tr>'; } echo "</table>"; } function ignore_form() { echo '<h3>Ignore Mail From A Specified User</h3> The user will not be able to send you ingame mail. <form action="'.$_SERVER['PHP_SELF'].'?action=ignoresub" method="post"> ID of person to ignore: <input type="text" name="blid" /> Reason For User Ignore: <input type="text" name="reason" /> <input type="submit" value="Ignore Future Mail" /></form>'; } function ignore_submit() { global $db,$userid; $blid = mysql_real_escape_string($_POST['blid']); $reson = mysql_real_escape_string($_POST['reason']); $select = sprintf(("SELECT `userid`, `user_level` FROM `users` WHERE userid = %u"), $blid); $ul2 = $db->query($select); $ul=$db->fetch_row($ul2); if(empty($blid) or $blid == 0) { echo 'You did not enter a userid. [url="'.$_SERVER['PHP_SELF'].'?action=ignoreform"]Back[/url]'; } else if($ul['userid'] != $blid) { echo 'You can\'t ignore a non-existant user. [url="'.$_SERVER['PHP_SELF'].'?action=ignoreform"]Back[/url]'; } else if($ul['user_level'] != 1) { echo 'You can\'t ignore staff. [url="'.$_SERVER['PHP_SELF'].'?action=ignoreform"]Back[/url]'; } else if($blid == $userid) { echo 'You can\'t ignore yourself. [url="'.$_SERVER['PHP_SELF'].'?action=ignoreform"]Back[/url]'; } else { $insert = sprintf("INSERT INTO `ignore` (`userid`, `blocked`, `reason`) VALUES('%u', '%u', '{$_POST['reason']}')", $userid, $blid, $reason); $db->query($insert); echo 'Users Mail will be Ignored. [url='.$_SERVER[']Return to ignore[/url]'; } } function unignore() { global $db,$userid; $delete = sprintf(("DELETE FROM `ignore` WHERE id=%u AND userid=%u"), mysql_real_escape_string($_GET['id']), $userid); $db->query($delete); echo 'User un-ignored. [url='.$_SERVER[']Return to ignore[/url]'; } $h->endpage(); ?> Cheers haunted ;) damn hes got good eyes has our DAWG he spotted a ' when its hould have been ` DOH! lol cheers pal ;)
-
Re: [mccode v2] Ignore User Mail Ive made an update to thiss but seem to be having a few issues from Tonkas copy which works fine up until i added my parts so just to make those AWARE tonkas copy works fnie without the edits here.. just need some help. Ive created a new table on the ignore called reason varchar (255) not null add to the insert $insert = sprintf("INSERT INTO `ignore` (`userid`, `blocked`, `reason`) VALUES('%u', '%u', '{$_POST['reason']}')", $userid, $blid, $reason); Ok now the reason is inserted into the dbase but the text wont appear when someone goes back to the ignore script the REASON is just blank ive placed echo '</td><td>'; echo $reason; echo '</td><td>'; So it calls for the statement but its coming up blank... Any ideas
-
[MMCODE V2] Set Sell Price of houses after they are Purchased...
Uridium replied to Uridium's topic in Free Modifications
Re: [MMCODE V2] Set Sell Price of houses after they are Purchased... Destroyer.. all mods for MCC are useless thats why we create them, in the hope some people may see through the Uslessness of them and try making something from it :) -
Re: NOT a MOD just an Idea This post allows you to set a sell price http://criminalexistence.com/ceforums/index.php?topic=29121.0
-
Re: Quests!! I think he's doing fine on his own. As a first script i think we can certainly see some more decent scripts from him :) Sorry Danny wasnt aware you took part but yeah i'll +1 you :)
-
The houses on MCC are always at a set price even though i made a mod so when you sell them you could sell them at half the amount. so my thinknig is if a house can be bought new at say $50,000 and sold at $25,000 then why cant a user buy the house which was sold at $25,000 with reduced will as its now second hand :)
-
Re: Quests!! I'll +1 ya :) i havent tried it but looked over it
-
[Mccodes V2] [BIG MOD] Trading Card Game [$15]
Uridium replied to Joel's topic in Paid Modifications
Re: [Mccodes V2] [bIG MOD] Trading Card Game [$15] Damn joel lol your killing my way of thinking its great when it becomes obsessive Excellent Addition, Excellent Aspect and finally An original Idea Tru to form :) +1