Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if ($_GET['mailbomb'] == "search")
- {
- if ($_POST['submit'] == "Yes")
- {
- if ($user_class->money < 300000)
- {
- echo Message("Sorry. You dont have enough money to search for mailbombs.");
- include "footer.php";
- exit();
- }
- else
- {
- $mailbombs = mysql_query("SELECT * FROM `pms` WHERE `to` = {$user_class->id} AND `mailbomb` = 1 AND `mailbombfound` = 0");
- $newmoney = $user_class->money - 300000;
- mysql_query("UPDATE `grpgusers` SET `money` = $newmoney WHERE `id` = {$_SESSION['id']}");
- if (mysql_num_rows($mailbombs))
- {
- echo Message("You have successfully managed to search for mailbombs, and found a total of <b>".mysql_num_rows($mailbombs)." mailbombs</b>!<br><br>
- The mails which contained mailbombs have been highlighted in bold red on your mailbox.<br><br>
- <a href='mailbox.php' />Go Back</a>");
- mysql_query("UPDATE `pms` SET `mailbombfound` = 1 WHERE `to` = {$_SESSION['id']} AND `mailbomb` = 1");
- include "footer.php";
- exit();
- }
- else
- {
- if (!mysql_num_rows($mailbombs))
- {
- echo Message("You have successfully managed to search for mailbombs, but no mailbombs were found.<br><br>
- <a href='mailbox.php' />Go Back</a>")
- include "footer.php";
- exit();
- }
- }
- }
- }
- else
- {
- echo "
- <tr><td class-'contentcontent'>
- Searching for mail bombs costs $300,000, and has a 90% chance of being successfull. Are you sure you want to continue?<br><br>
- <center>
- <form method='post'>
- <input type='submit' value='Yes' name='submit'>
- </form>
- </center>
- </td></tr>
- ";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement