Jump to content
MakeWebGames

Recommended Posts

Posted

Re: [HELP] same ip

will the ones for v1 work with v2 and how do i convert v1 to v2 beacuse i want this register page

 

<?php
session_start();
print "<html>
<head>
<title>Crime-city</title>
<style>
body { font-family:Verdana;font-size:9pt;color: white;
  background-color:#000000;
  scrollbar-base-color: #005B70;
  scrollbar-arrow-color: #F3960B;
  scrollbar-DarkShadow-Color: #000000; }
a:visited,a:active,a:hover,a:link { color: blue;text-decoration: none; }
table,tr,td { font-size:9pt; }
img { border:none; }

</style>
</head>
<body><table width='100%' border='1' bgcolor='#000000'>
 <tr>
   <th scope='col'>[img=logo.png]</th>
 </tr>
</table>




<center>    ";
$ip = ($_SERVER['HTTP_X_FORWARDED_FOR'])
   ?  $_SERVER['HTTP_X_FORWARDED_FOR']
   :  $_SERVER['REMOTE_ADDR'];
if(file_exists('ipbans/'.$ip))
{
die("[b]<font color=red size=+1>Your IP has been banned, there is no way around this.</font>[/b]</body></html>");
}
require "mysql.php";
global $c;
if($_POST['username'])
{
$sm=100;
if($_POST['promo'] == "908")
{
$sm+=100;
}
$username=$_POST['username'];
$username=str_replace(array("<", ">"), array("<", ">"), $username);
$q=mysql_query("SELECT * FROM users WHERE username='{$username}'",$c);
if(mysql_num_rows($q))
{
print "Username already in use. Choose another.";
}
else if($_POST['password'] != $_POST['cpassword'])
{
print "The passwords did not match, go back and try again.";
}
else
{
$_POST['ref'] = abs((int) $_POST['ref']);
$ip = ($_SERVER['HTTP_X_FORWARDED_FOR'])
   ?  $_SERVER['HTTP_X_FORWARDED_FOR']
   :  $_SERVER['REMOTE_ADDR'];
$q=mysql_query("SELECT * FROM users WHERE lastip='$ip' AND userid={$_POST['ref']}",$c);
$a=mysql_query("SELECT * FROM users WHERE lastip='$ip'",$c);
if(mysql_num_rows($a) > 0)
{
die("No multi's! Your not trying to make another account are you! Sorry! Not Allowed!");
}
if(mysql_num_rows($q))
{
die("Creating Referral Multies Is Not Aloud.");
}
if($_POST['ref']) {
$q=mysql_query("SELECT * FROM users WHERE userid={$_POST['ref']}",$c);
$r=mysql_fetch_array($q);
}
mysql_query("INSERT INTO users (username, login_name, userpass, level, money, user_level, energy, maxenergy, will, maxwill, brave, maxbrave, hp, maxhp, location, gender, signedup, email,  lastip) VALUES( '{$username}', '{$username}', md5('{$_POST['password']}'), 1, $sm,  1, 12, 12, 100, 100, 5, 5, 100, 100, 1, '{$_POST['gender']}', unix_timestamp(), '{$_POST['email']}',  '$ip')", $c);
$i=mysql_insert_id($c);
mysql_query("INSERT INTO userstats VALUES($i, 10, 10, 10, 10, 10)", $c);

if($_POST['ref']) {
require "global_func.php";
mysql_query("UPDATE users SET crystals=crystals+2 WHERE userid={$_POST['ref']}",$c);
event_add($_POST['ref'],"For refering $username to the game, you have earnt 2 valuable crystals!",$c);
mysql_query("INSERT INTO referals VALUES('', {$_POST['ref']}, $i, unix_timestamp(),'{$r['lastip']}','$ip')", $c);
}
print "Thank You For Registering! Please Login.

> [url='login.php']Login[/url]";
}
}
else
{
print "<style type='text/css'>
<!--
#Layer2 {
  position:absolute;
  width:200px;
  height:115px;
  z-index:1;
  left: 354px;
  top: 356px;
}
#Layer6 {
  position:absolute;
  width:182px;
  height:202px;
  z-index:2;
  left: 10px;
  top: 204px;
}
#Layer7 {
  position:absolute;
  width:200px;
  height:115px;
  z-index:3;
  left: 350px;
  top: 201px;
}
#Layer8 {
  position:absolute;
  width:1081px;
  height:33px;
  z-index:4;
  left: 71px;
  top: 590px;
}
-->
</style>
<body bgcolor='#000000'>
<div id='Layer7'>

 <table width='530' height='109' border='1' bgcolor='#000000'>
   <tr>
     <th scope='col'> Crime-city Registration</th>
   </tr>
<td>
  <center>

        <form action=register.php method=post>

<table width='530' border='1'>


<td><div align='center'>Username:</div></td>
   <td><div align='center'>     
<input type='text' name='username' />
   </div></td>
 </tr>
 <tr>
   <td><div align='center'>Password:</div></td>
   <td><div align='center'>
     <input type='password' name='password' />
   </div></td>
 </tr>
 <tr>
   <td><div align='center'>Confirm Password: </div></td>
   <td><div align='center'>
     <input type='password' name='cpassword' />
 Gender: <select type='dropdown' name='gender'><option value='male'>Male</option><option value='female'>Female</option></select>


   </div></td>
 </tr>
 <tr>
   <td><div align='center'>Email Address: </div></td>
   <td><div align='center'>
     <input type='text' name='email' />
   </div></td>
 </tr>
 <tr>
   <td><div align='center'>Promo Code: </div></td>
   <td><div align='center'>
     <input type=text name=promo />
   </div></td>
 </tr>
 <tr> </tr>
</table>

<input type=hidden name=ref value='";
if($_GET['REF']) { print $_GET['REF']; }
print "'>
<input type=submit value=Submit></form><form name=tos>
<input type='checkbox' name=mybox value='1'>I Agree To The Terms Of Service
</form>
     </center></td>
   </tr>
 </table>
</div>
<div id='Layer6'>
 <table width='181' height='203' border='1' bgcolor='#000000'>
   <tr>
     <th height='39' scope='col'>Navigation</th>
   </tr>
   <tr>
     <td height='30'>[url='login.php']Login[/url]</td>
   </tr>
   <tr>
     <td height='28'>[url='register.php']Register[/url]</td>
   </tr>
   <tr>
     <td height='30'>[url='#']Lost Password?[/url]</td>
   </tr>
   <tr>
     <td height='30'>[url='#']Screenshots[/url]</td>
   </tr>
   <tr>
     <td height='30'>[url='tos.php']Terms Of Service[/url]</td>
   </tr>
 </table>
</div>
<div id='Layer8'>
table width='98%' border='1' bgcolor='#000000'>
   <tr>
     <th scope='col'><center>
       | This Game Is Brought To You By solar! |
     </center>";
}
print "</body></html>";
?>

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...