Jump to content
MakeWebGames

SMOKEY_TEK

Members
  • Posts

    126
  • Joined

  • Last visited

  • Days Won

    1

SMOKEY_TEK last won the day on May 23 2011

SMOKEY_TEK had the most liked content!

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

SMOKEY_TEK's Achievements

Newbie

Newbie (1/14)

1

Reputation

  1. Okay, I understand how that works now. Thanks sniko
  2. Thanks for the link Djkanna, I'm just confused on the a href links as it shows "<a href="javascript:void(0);" target="_blank">".. How does it know which to follow? What I mean is if a player doesn't have an account and they click on "Open an account" how does it know that is what the users is clicking on if it says "javascript:void(0);" ?
  3. Would it be possible to add the file again? When it was transferred to the new MWG site it screwed up the script.. Thanks!
  4. For those that messaged me, I appreciate it but I will no longer need any assistance with this as I will be investing in a new script that is totally secured and whatnot..
  5. Yea I know, I previously changed my scripts so I haven't rechanged it back to the original GRPG way..
  6. I know for a fact skooda did not code this game engine as I bought the same engine from a friend which was a friend from the owner of the script that is being sold here..
  7. My game is currently using the GRPG script, but I'm having trouble securing it lol.. So if you could fix it I would totally pay you for the work you have done.. Send me a PM if your interested.. Link to my game: http://www.hitmanmassacre.com
  8. Anybody know how "Gang Ranks" could be done? Let's say, You created a gang, it would insert that new gang in the database and you have the rank "Leader" and if another player joined your gang they would have a rank "Member". Leader and Member rank would automatically be in every gangs ranks. But the leader could create/edit gang ranks for that gang, which would have checkboxes next to things that rank can manage in the gang i.e: Vault, Members, Ranks, Invitations, Crimes, Gang Page, Gang Profile, Applications, Gang Name/Tag, and Mass Mail. And could update any member of the gang to that new rank.. I've tried to do this, but I can't get it to work...
  9. What would it be called to have pages load like the following http://www.yourgamename.com/index.php?do=city ? Here is a little code to what I'm meaning   <?php $page = $_REQUEST['do']; file_exists($page.".php") ? include($page.".php") : include("homepage.php");?>
  10. Cronic, Replace your register.php with the code below:   <?php include (DIRNAME(__FILE) . '/notloggedinh.php'); function getRealIp() { if (!empty($_SERVER['HTTP_CLIENT_IP'])) { //check ip from share internet $ip=$_SERVER['HTTP_CLIENT_IP']; } elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) { //to check ip is pass from proxy $ip=$_SERVER['HTTP_X_FORWARDED_FOR']; } else { $ip=$_SERVER['REMOTE_ADDR']; } return $ip; } $ip = getRealIp(); function clean($str) { $str = @trim($str); if(get_magic_quotes_gpc()) { $str = stripslashes($str); } return mysql_real_escape_string($str); } if (isset($_POST['registerSubmit'])) { $login_name = clean($_POST['loginName']); $registerPassword = clean($_POST['registerPassword']); $confirmPassword = clean($_POST['confirmPassword']); $PASSWORD = hash("sha512", $_POST["registerPassword"]); $registerEmail = clean($_POST['registerEmail']); $confirmEmail = clean($_POST['confirmEmail']); $activateCode = clean(rand(11111111,99999999)); $registerToS = $_POST['registerToS']; $registerGender = clean($_POST['registerGender']); $date = time(); @session_start(); if ($_SESSION['AntiSpamImage'] != $_REQUEST['anti_spam_code']) { $_SESSION['AntiSpamImage'] = rand(1,9999999); $message .= "<div>The verification code you entered is invalid.</div>"; } $checkuser = mysql_query("SELECT * FROM `grpusers` WHERE `loginame`='$login_name'"); $username_exist = mysql_num_rows($checkuser); if($username_exist > 0) { $message .= "<div>The Login Name you entered is already in use.</div>"; } $checkemail = mysql_query("SELECT * FROM `grpgusers` WHERE `email` ='$registerEmail'"); $email_exist = mysql_num_rows($checkemail); if($email_exist > 0) { $message .= "<div>The Email you entered is already in use.</div>"; } if(strlen($login_name) < 3 or strlen($login_name) > 16) { $message .= "<div>Your Login Name must be between 3-16 characters.</div>"; } if(strlen($registerPassword) < 5 or strlen($registerPassword) > 16) { $message .= "<div>Your Password must be between 5-16 characters.</div>"; } if($registerPassword != $confirmPassword) { $message .= "<div>Your passwords don't match. </div>"; } if($registerToS != checked) { $message .= "<div>You need to agree with the Terms of Service.</div>"; } if (!eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$", $registerEmail)) { $message .= "<div>The e-mail address you entered was invalid.</div>"; } if($registerEmail != $confirmEmail) { $message .= "<div>Your emails don't match.</div>"; } //insert the values if (!isset($message)){ // now we insert it into the database $insert = mysql_query("INSERT INTO `users` (`loginame`, `username`, `password`, `email`, `ip`, `signuptime`, `lastactive`, `gender`, `verified`, `activateCode`)". "VALUES ('$login_name', '$login_name', '$PASSWORD', '$registerEmail', '$ip', '$date', '$date', '$registerGender', '0', '$activateCode')") or die(mysql_error()); $add_member = mysql_query($insert); $emailSubject = "Mafia Heros: Account Registration Confirmation"; $headers = "From: Mafia Heros"; $headers = "MIME-Version: 1.0"; $headers = "Content-Type: text/html; charset=ISO-8859-1"; $emailBody = " <html><body> <h2>Welcome to Mafia Heros</h2> <p> This email has been sent from http://www.mafiaheros.com. You have received this email because your address was used to register on Mafia Heros. </p> <p> If you did not register, please disregard this email. You do not need to unsubscribe or take any further action. </p> <h3>Activation Instructions</h3> <p> We require that you validate your registration to ensure that the email address you entered was correct. This protects against unwanted spam and malicious abuse. </p> <p> You registered with the login name '".$login_name."' your password: '".$registerPassword."''. To activate your account, simply click on the following link: <a href='http://www.mafiaheros.com/activate.php?activateCode=$activateCode&user=$login_name' target='_blank' onclick='onClickUnsafeLink(event);'>http://www.mafiaheros.com/activate.php?activateCode=$activateCode&user=$login_name</a> </p> <p> For questions or concerns about your account, please contact us via contact form <a href='http://www.mafiaheros.com/contactus.php' target='_blank' onclick='onClickUnsafeLink(event);'>http://www.mafiaheros.com/contactus.php</a> </p> </body></html>"; mail($registerEmail, $emailSubject, $emailBody, $headers); echo Message("You successfully created an account. We sent an activation link to the listed email '<b>".$registerEmail."</b>'."); if ($_POST['referer'] != ""){ $result12 = mysql_query("SELECT * FROM `grpgusers` WHERE `loginame`='".$login_name."'"); $worked12 = mysql_fetch_array($result12); $result= mysql_query("INSERT INTO `referrals` (`when`, `referrer`, `referred`)". "VALUES ('$date', '".$_POST['referer']."', '".$worked12['id']."')"); } die(); } } ?> <? if (isset($message)) { echo Message($message); } ?> <div id="right_c"> <div class="g_content"> <h3> Register</h3> <div class="g_text"> <center>You will need to register with an valid e-mail address, After signing up you have to activate your account.</center> <form name='register' method='post' action='register.php'> <table width='60%' border='0' align='center' cellpadding='0' cellspacing='2'> <tr> <td><b>Username:</b></td> <td><input type='text' name='login_name' size='30'></td> </tr> <tr> <td><b>Email:</b></td> <td><input type='text' name='registerEmail' size='30'></td> </tr> <tr> <td><b>Confirm Email:</b></td> <td><input type='text' name='confirmEmail' size='30'></td> </tr> <tr> <td><b>Password:</b></td> <td><input type='password' name='registerPassword'></td> </tr> <tr> <td><b>Confirm Password:</b></td> <td><input type='password' name='confirmPassword'></td> </tr> <tr> <td><b>Gender:</b></td> <td><select name="registerGender"> <option value="Male">Male</option> <option value="Female">Female</option> </select></td> </tr> <tr> <td><b>ToS:</b></td> <td>I have read and agree to follow the ToS <input type="checkbox" name='tos' value="checked" /></td> </tr> <tr> <td><b>Image Verification:</b></td> <td><img src="antispam.php" /></td> </tr> <tr> <td><b>Verify Code Above:</b></td> <td><input type='text' name='anti_spam_code'></td> </tr> <tr> <td> </td> <td> <input type='hidden' name='referer' value='<? echo $_GET['referer'] ?>'> <input type='submit' name='registerSubmit' value='Register'> </td> </tr> </table> </form> </div> </div> </div> <? include (DIRNAME(__FILE__) . '/notloggedinf.php'); ?>   Make a file called activate.php and insert the code below into it and save. <?php include (DIRNAME(__FILE) . '/global.php'); $activateCode = $_GET["activateCode"]; $user = $_GET["user"]; if(!$activateCode){ echo " <div class='content'> <h3>Activate Account</h3> <p>No activation code supplied.</p> </div>"; die(); } else { $check = mysql_query("SELECT * FROM `users` WHERE `activateCode` = '$activateCode' AND `username` = '$user' AND `verified` = '1'"); if($check == 1) { echo " <div class='content'> <h3>Activate Account</h3> <p>You have already activated your account.</p> </div>"; die(); } else { $activate = mysql_query("UPDATE `users` SET `verified` = '1' WHERE `activateCode` = '$activateCode' AND `user` = '$user'"); echo " <div class='content'> <h3>Activate Account</h3> <p>Your account has been successfully activated. You may login now. </p> </div>"; die(); } } ?>   Add these to your grpgusers database: verified int(1) NOT NULL default '0' activateCode VARCHAR(200) NOT NULL;
  11. Thanks I'll give it a try in a little bit, and let you know ... Thanks again!
  12. Does anyone know how I could change the way the experience is set up in the GRPG script? What I mean is, as of right now when your like level 45 you have 12 million exp, and it doesn't seem right to me.. I would like it to be lower way lower than it is now. Here's the experience and level code:   function experience($L) { $a=0; $end=0; for($x=1; $x<$L; $x++) { $a += floor($x+1500*pow(4, ($x/7))); } return floor($a/4); } function Get_The_Level($exp) { $a=0; $end =0; for($x=1; ($end==0 && $x<100); $x++) { $a += floor($x+1500*pow(4, ($x/7))); if ($exp >= floor($a/4)){ } else { return $x; $end=1; } } } function Get_Max_Exp($L){ $end=0; if ($exp == 0){ return 457; $end =1; } for($L=1;($L<100 && $end==0);$L++) { $exp = experience($L); //echo $exp; if ($exp >= $user_class->exp){ return $exp; $end=1; } } }   Thanks, James
  13. What can't you get it to work?
  14. This is the file that reads the messages.. It's called mailbox_read.php   <?php include (DIRNAME(__FILE__) . '/header.php'); include (DIRNAME(__FILE__) . '/parser.php'); $_GET['sent'] = abs(intval($_GET['sent'])); if($_GET['sent']){ echo " <div class='content'> <h3>Mailbox</h3> <table width='100%'>"; $result = mysql_query("SELECT * from `mailbox` WHERE `id`='".$_GET['sent']."'"); $row = mysql_fetch_array($result); $from_user_class = new User($row['mailFrom']); $mailBody = $row['mailBody']; $subject = ($row['mailSubject'] == "") ? "No Subject" : $row['mailSubject']; if ($_GET['sent'] != ""){ echo " <table width='100%'> <tr> <td width='25%'><h4>Sender</h4></td> <td>".$from_user_class->formattedname."</td> </tr> <tr> <td width='25%'><h4>Received</h4></td> <td>".date(F." ".d.", ".Y." ".g.":".i.":".sa,$row['mailTime'])."</td> </tr> <tr> <td width='25%'><h4>Subject</h4></td> <td>".$subject."</td> </tr> <tr> <td colspan='2'><h4>Message</h4></td> </tr> <tr> <td colspan='2'><p>"; ?> <?php $formatted_text=bb_code(bbcode($mailBody)); echo $formatted_text; echo "</p></td></td> </tr> <tr> <td colspan='2'><h4>Actions</h4></td> </tr> <tr> <td colspan='2'> <table width='100%'> <tr> <td width='25%' align='center'><a href='mailbox.php?mail=new&mailTo=".$from_user_class->id."&reply=".$row['id']."'>Reply</a></td> <td width='25%' align='center'><a href='mailbox_read.php?id=".$row['id']."&save=1'>Save</a></td> <td width='25%' align='center'><a href='mailbox_read.php?id=".$row['id']."&del=true'>Delete</a></td> <td width='25%' align='center'><a href='mailbox_read.php?id=".$row['id']."&report=yes'>Report</a></td> </tr> <tr> <td width='25%' align='center'><a href='contacts_add.php?id=".$from_user_class->id."'>Add Contact</a></td> <td width='25%' align='center'><a href='ignores_add.php?id=".$from_user_class->id."'>Ignore</a></td> <td width='25%' align='center'> </td> <td width='25%' align='center'> </td> </tr> </table> </td> </tr> </table> <p><a href='mailbox.php?mail=inbox'>Back</a></p> </div>"; die(); } } ?> <div class='content'> <h3>Mailbox</h3> <table width='100%'> <?php $_GET['id'] = abs(intval($_GET['id'])); $result = mysql_query("SELECT * from `mailbox` WHERE `id`='".$_GET['id']."'"); $row = mysql_fetch_array($result); $from_user_class = new User($row['mailFrom']); $mailBody = $row['mailBody']; $subject = ($row['mailSubject'] == "") ? "No Subject" : $row['mailSubject']; if ($_GET['id'] != ""){ if (strtoupper($row['mailTo']) == strtoupper($user_class->id)) { echo " <table width='100%'> <tr> <td width='25%'><h4>Sender</h4></td> <td>".$from_user_class->formattedname."</td> </tr> <tr> <td width='25%'><h4>Received</h4></td> <td>".date(F." ".d.", ".Y." ".g.":".i.":".sa,$row['mailTime'])."</td> </tr> <tr> <td width='25%'><h4>Subject</h4></td> <td>".$subject."</td> </tr> <tr> <td colspan='2'><h4>Message</h4></td> </tr> <tr> <td colspan='2'><p>"; ?> <?php $formatted_text=bb_code(bbcode($mailBody)); echo $formatted_text; echo "</p></td></td> </tr> <tr> <td colspan='2'><h4>Actions</h4></td> </tr> <tr> <td colspan='2'> <table width='100%'> <tr> <td width='25%' align='center'><a href='mailbox.php?mail=new&mailTo=".$from_user_class->id."&reply=".$row['id']."'>Reply</a></td> <td width='25%' align='center'><a href='mailbox_read.php?id=".$row['id']."&save=1'>Save</a></td> <td width='25%' align='center'><a href='mailbox_read.php?id=".$row['id']."&del=true'>Delete</a></td> <td width='25%' align='center'><a href='mailbox_read.php?id=".$row['id']."&report=yes'>Report</a></td> </tr> <tr> <td width='25%' align='center'><a href='contacts_add.php?id=".$from_user_class->id."'>Add Contact</a></td> <td width='25%' align='center'><a href='ignores_add.php?id=".$from_user_class->id."'>Ignore</a></td> <td width='25%' align='center'> </td> <td width='25%' align='center'> </td> </tr> </table> </td> </tr> </table> <p><a href='mailbox.php?mail=inbox'>Back</a></p>"; $result2 = mysql_query("UPDATE `mailbox` SET `mailRead` = '1' WHERE `id`='".$row['id']."'"); } } ?> </div>
  15. Okay, I tried both of these suggestions but I am still getting that annoying "rn" when I look at a message... I tried putting it in the actual mailbox.php file and my mailbox_read.php file.. Could it be something with my BBcode Parser?
×
×
  • Create New...