<?php //Database Connectivity include_once "dbinfo.inc.oop.php"; session_start(); if (!isset($_SESSION['umail'])) { header('Location: index.php'); } $user_details = getUserDetailsByEmail($_SESSION['umail']); $user = mysqli_fetch_array($user_details); $uid = $user['user_id']; ?> <!DOCTYPE html> <html lang="en"> <!---------------------------------------- Created by: Saurav Majumder All Rights Reserved to Wizlyst.com ------------------------------------------> <head> <title>My Account - <?php if ($user['user_type'] == "individual") { echo $user['user_fname'] . " " . $user['user_lname']; } else { echo $user['user_cname']; } ?> </title> <link rel="shortcut icon" type="image/x-icon" href="img/favicon.ico">
<font color="red"> <? if ($cgi['submit']) { if (($HTTP_SERVER_VARS['REMOTE_ADDR']) && (isIP($HTTP_SERVER_VARS['REMOTE_ADDR']))) { $echoS = "Oops. Somebody has already registered from this IP. If you beleive it is a fault you can contact us via mail {$conf['mail']}."; } elseif (!$cgi['username']) { $echoS = "You should enter user name."; } elseif (getUserDetailsByName($cgi['username'])) { $echoS = "That username has already been taken."; } elseif ($cgi['email'] != $cgi['email2']) { $echoS = "Mails you have entered are not equal."; } elseif (!preg_match("/^.+?@.+?\..+?/i", $cgi['email'])) { $echoS = "You should enter correct e-mail."; } elseif (strpos($cgi['email'], "hotmail.com") > 0) { $echoS = "We have been getting too many complaints that hotmail blocks our activation emails, please use an alternate email such as <a href=\"http://www.gmail.com\" target=\"_blank\">Gmail</a>"; } elseif (getUserDetailsByEmail($cgi['email'])) { $echoS = "That e-mail has already been taken."; } elseif (!$cgi['tos']) { $echoS = "You should agree to comply with the terms of service."; } elseif (!$cgi['rules']) { $echoS = "You should agree to comply with the rules."; } elseif (!$cgi['cheat']) { $echoS = "You should promise not to try to gain an unfair advantage by breaking the rules."; } elseif (!$cgi['account']) { $echoS = "You should agree to have ONLY one " . $conf["sitename"] . " account."; } elseif (!$cgi['turing'] || (strtolower($cgi['turing']) != strtolower($_SESSION['number']))) { $echoS = "You should type the text that you see on the image."; } else { //echo "Registering"; $isResistered = 1; $pas = genRandomPas();
$type = $_POST['type']; $f_name = $_POST['f_name']; $l_name = $_POST['l_name']; $c_name = $_POST['c_name']; $email = $_POST['email']; $password = $_POST['password']; $address = $_POST['address']; $phone = $_POST['phone']; $url = $_POST['url']; $tc = $_POST['tc']; $newsletter = $_POST['newsletter']; //echo $type." - ".$f_name." - ".$l_name." - ".$c_name." - ".$email." - ".$password." - ".$address." - ".$phone." - ".$url." - ".$tc." - ".$newsletter; $result = signUp($type, $f_name, $l_name, $c_name, $email, $password, $address, $phone, $url, $newsletter); if ($result) { $_SESSION['umail'] = $email; $user_details = getUserDetailsByEmail($email); $user = mysqli_fetch_array($user_details); ?> <div class="alert alert-success" id="login-success"> <strong>Well Done!</strong> You are signed up successfully! <br><br> <p> <strong>User ID:</strong> <span id="User_id"><?php echo $user['user_id']; ?> </span> <br> <strong>Name:</strong> <?php if ($user['user_type'] == "individual") { echo $user['user_fname'] . " " . $user['user_lname'];
<?php //Database Connectivity include_once "dbinfo.inc.oop.php"; include_once "email.php"; $email = $_POST['email']; $result = getUserDetailsByEmail($email); $count = mysqli_num_rows($result); if ($count > 0) { $user = mysqli_fetch_array($result); $new_password = randomPassword(); $result2 = recovPassword($user['user_id'], $new_password); if ($result && passwordRecoveryEmail($email, $new_password)) { ?> <div class='alert alert-success'>Your password has been sent to <strong><?php echo $email; ?> </strong>.</div> <?php } else { ?> <span id="recov_pass_notification"> <div class='alert alert-danger'>Internal Error Occured. Try Again.</div> </span> Please enter the email address you used to sign up / post ad on FlickBazar. We will email you the password. <form class="form-horizontal" method="POST" name="recov_pass_form" id="recov_pass_form" action=""> <fieldset> <div class="control-group"> <label class="control-label" for="recov_pass_email">Email</label> <div class="controls">