<?php session_destroy(); unset($_SESSION); header("location:" . mainPageURL());
} if (empty($error)) { if (!verifyLoginCustomer($data_login)) { $_SESSION['error_warning'] = $lang['error_failed_login']; header('Location:login.html'); } else { $customer_data = getCustomerByEmail($data_login); if ($customer_data['status'] == 0) { $_SESSION['error_warning'] = $lang['error_failed_activation']; header('Location:login.html'); } else { $success = $lang['success_login']; $_SESSION['coin_id'] = $customer_data['customer_id']; $_SESSION['start'] = time(); $_SESSION['expire'] = $_SESSION['start'] + 1 * 60; header('Location:' . mainPageURL()); } } } else { $_SESSION['error_warning'] = $error['email']; header('Location:login.html'); } } if (isset($_POST["btnReg"])) { $email = mysql_real_escape_string($_POST["email_reg"]); if (verifyDuplicateCustomer($email, "email")) { $_SESSION['error_warning'] = $lang['error_email_duplicate']; } else { $_SESSION['email'] = $email; } header("location:register.html");
<?php session_destroy(); unset($_SESSION); header("location:" . mainPageURL() . "admin/");
<script> FB.init({appId: "<?php echo $fbshare; ?> ", status: true, cookie: true}); function postToFeed() { var obj = { method: 'feed', redirect_uri: '<?php echo mainPageURL(); ?> ', link: 'http://localhost/coin/product18-brand1-model1.html', picture: '<?php echo mainPageURL(); ?> /data/image/<?php echo $images_show; ?> ', name: '<?php echo $product['brand'] . " " . $product['model']; ?> ', caption: ' ', description: '<?php echo strip_tags($product['description']); ?> ' };
</ul> </td> </tr> </tbody> </table> </nav> <!--end div menu--> <?php if (isset($logged)) { $now = time(); if ($now > $_SESSION['expire']) { session_destroy(); echo "<script language='javascript'>\n\t\t\t\t\t\t\twindow.location=" . mainPageURL() . ";\n\t\t\t\t\t\t\talert('Timeout!!!Please login to continue browsing the site');\n\t\t\t\t\t\t</script>"; } else { echo '<div id="search"> <form action="' . mainPageURL() . '" enctype="multipart/form-data" name="searchForm" id="myForm" method="GET"> <input type="text" class="search_input" name="search" placeholder="Enter Search..." value="" /> </form> </div>'; $_SESSION['start_reset'] = time(); $_SESSION['expire'] = $_SESSION['start_reset'] + 30 * 60; $customer = getCustomerById($logged); $username = $customer['username']; $token = $customer['token']; $gravatar_image = $customer['email']; $gravatar_default = ""; $size = 40; $grav_url = "http://www.gravatar.com/avatar/" . md5(strtolower(trim($gravatar_image))) . "?d=" . urlencode($gravatar_default) . "&s=" . $size; echo '<div id="after_log_in"> <div class="user_name"> <img src="' . $grav_url . '" alt="" />
if (isset($_POST['emails'])) { $emails = $_POST['emails']; } else { $emails = ''; } if (isset($_POST["btnGet"])) { $emails = mysql_real_escape_string($_POST['emails']); if (verifyDuplicateCustomer($emails, "email")) { $code = sha1(uniqid(mt_rand(), true)); $data_emails = array('email' => $emails); $customer = getCustomerByEmail($data_emails); $edit_data = array('customerId' => $customer['customer_id'], 'fcode' => $code); $edit_query = editCustomer($edit_data); if ($edit_query) { $subject = $lang['text_password_reset']; $body = "Dear " . $customer['username'] . ", \n\t\t\t\t\t<br><br/>\n\t\t\t\t\tPlease <a href='" . mainPageURL() . "resetpassword/" . base64_encode(urlencode($emails)) . "/" . $code . ".html'>Click Here</a> to reset your password.<br/><br/>\n\t\t\t\t\tIf the above link does not work, you can paste the following address into your browser:<br/><br/>\n\t\t\t\t\t" . mainPageURL() . "resetpassword/" . base64_encode(urlencode($emails)) . "/" . $code . ".html<br/><br/>\n\t\t\t\t\t<br/>\n\t\t\t\t\tEnjoy your awesome first auction experience with " . $lang['text_company_name'] . ".\n\t\t\t\t\t<br /><br /> \n\t\t\t\t\tThank You! \n\t\t\t\t\t<br /><br />\n\t\t\t\t\tNOTE:If you did not request for this email. Kindly ignore it.\n\t\t\t\t\t<br /><br />\n\t\t\t\t\tBest Regards,\n\t\t\t\t\t" . $lang['text_company_name'] . " Management Team"; $data_mail = array('to_name' => $customer['username'], 'to_email' => $emails, 'subject' => $subject, 'body' => $body); sendMail($data_mail); $_SESSION['success'] = $lang['success_mail_password']; header("location:login.html"); } else { $error_warning = $lang['error_query']; } } else { $error_warning = $lang['error_email_not_exist']; } } $title = $lang['head_forgot_password']; ?> <h5><?php echo $lang['head_forgot_password'];
<?php if (!isset($logged)) { header('Location:login.html'); } if (!hasPermission($logged, 'access', 'user_group')) { header('Location:' . mainPageURL() . 'admin/permission.html'); } if (isset($_SESSION['error_warning'])) { $error_warning = $_SESSION['error_warning']; unset($_SESSION['error_warning']); } else { $error_warning = ''; } if (isset($_SESSION['success'])) { $success = $_SESSION['success']; unset($_SESSION['success']); } else { $success = ''; } if (isset($_GET['sort'])) { $sort = $_GET['sort']; } else { $sort = 'name'; } if (isset($_GET['order'])) { $order = $_GET['order']; } else { $order = 'ASC'; } if (isset($_GET['page'])) {
if (strlen($password) < 4 || strlen($password) > 20) { $error['password'] = $lang['error_password_valid']; } if ($password != $confirm) { $error['confirm'] = $lang['error_confirm']; } if (empty($error)) { $edit_data = array('customerId' => $customer['customer_id'], 'password' => md5($password), 'fcode' => "0"); $edit_query = editCustomer($edit_data); if ($edit_query) { $subject = $lang['success_reset_password']; $body = "Dear " . $customer['username'] . ", \n\t\t\t\t\t<br><br/>\n\t\t\t\t\tYour Password has been updated.<br/><br/>\n\t\t\t\t\t<br/>\n\t\t\t\t\tEnjoy your awesome first auction experience with " . $lang['text_company_name'] . ".\n\t\t\t\t\t<br /><br /> \n\t\t\t\t\tThank You! \n\t\t\t\t\t<br /><br />\n\t\t\t\t\tNOTE:If you did not request for this email. Kindly ignore it.\n\t\t\t\t\t<br /><br />\n\t\t\t\t\tBest Regards,\n\t\t\t\t\t" . $lang['text_company_name'] . " Management Team"; $data_mail = array('to_name' => $customer['username'], 'to_email' => $customer['email'], 'subject' => $subject, 'body' => $body); sendMail($data_mail); $_SESSION['success'] = $lang['success_reset_password']; header("location:" . mainPageURL() . "login.html"); } } else { $error_password = $error['password']; $error_confirm = $error['confirm']; } } $title = $lang['head_reset_password']; ?> <h5><?php echo $lang['head_reset_password']; ?> </h5> <article class="auction_container"> <?php if (isset($error_warning)) {
if (empty($country)) { $error['country'] = $lang['error_country_empty']; } if (empty($state)) { $error['state'] = $lang['error_state_empty']; } if (empty($phone)) { $error['phone'] = $lang['error_phone_empty']; } if (empty($error)) { $code = sha1(uniqid(mt_rand(), true)); $insert_data = array('username' => $username, 'email' => $emails, 'password' => md5($password), 'token' => 10, 'status' => 0, 'fcode' => $code, 'fname' => $firstname, 'lname' => $lastname, 'dob' => $dob, 'gender' => $gender, 'add1' => $add1, 'add2' => $add2, 'city' => $city, 'zip' => $zip, 'country' => $country, 'state' => $state, 'phone' => preg_replace("/[^0-9]+/", "", $phone)); $insert_query = insertCustomer($insert_data); if ($insert_query) { $subject = $lang['text_register_activation']; $body = "Dear " . $username . ", \n\t\t\t\t\t<br><br/>\n\t\t\t\t\tPlease Click link below to continue for register process. \n\t\t\t\t\t<br/><br/>\n\t\t\t\t\t<a href='" . mainPageURL() . "activation/" . urlencode(base64_encode($emails)) . "/" . $code . ".html'>Activate</a>\n\t\t\t\t\t<br/><br/>\n\t\t\t\t\tEnjoy your awesome first auction experience with Coincod.\n\t\t\t\t\t<br /><br /> \n\t\t\t\t\tThank You! \n\t\t\t\t\t<br /><br />\n\t\t\t\t\tNOTE:If you did not request for this email. Kindly ignore it.\n\t\t\t\t\t<br /><br />\n\t\t\t\t\tBest Regards,\n\t\t\t\t\tCoinCod Management Team"; $data_mail = array('to_name' => $username, 'to_email' => $emails, 'subject' => $subject, 'body' => $body); sendMail($data_mail); $_SESSION['success'] = $lang['success_register']; header("location:login.html"); } else { $_SESSION['error_warning'] = $lang['error_query']; header("location:register.html"); } } else { $error_username = $error['username']; $error_email = $error['email']; $error_password = $error['password']; $error_confirm = $error['confirm']; $error_fname = $error['fname']; $error_lname = $error['lname'];