<?php include './admin/config.php'; include './admin/db_connection.php'; include './admin/include/class.phpmailer.php'; include './admin/mail_template.php'; if(isset($_REQUEST['login_submit'])) { unset($_SESSION['sohorepro_userid']); unset($_SESSION['sohorepro_companyid']); unset($_SESSION['sohorepro_username']); $emailid= mysql_real_escape_string($_POST['email_id']); $pass= mysql_real_escape_string($_POST['password']); $rememberme= mysql_real_escape_string($_POST['rememberme']); $user_login = UserLogin($emailid,$pass); $chk_cus_status = CheckCusStatus($user_login[0]['cus_compname']); // echo '<pre>'; // print_r($user_login); // echo '</pre>'; // exit; // // // // foreach ($user_login as $login_pre){ // $check_status[] = StatusCheckComp($login_pre['cus_compname']); // } // //
<?php include './admin/config.php'; include './admin/mail_template.php'; if (isset($_REQUEST['order_val']) == '1') { extract($_POST); $cus_contact_name = $reg_fname . ' ' . $reg_lname; $sql = "INSERT INTO sohorepro_customers SET\r\r\n cus_fname = '" . $reg_fname . "', \r\r\n cus_lname = '" . $reg_lname . "',\r\r\n cus_email = '" . $reg_email_id . "',\r\r\n cus_pass = '******',\r\r\n cus_compname = '" . $customer_id_new . "',\r\r\n cus_contact_name = '" . $cus_contact_name . "',\r\r\n cus_contact_email = '" . $reg_email_id . "',\r\r\n cus_contact_phone = '" . $reg_user_phone . "', \r\r\n cus_status = '1' "; mysql_query($sql); $notifi_to_iser = CreateUsrNoti($customer_id_new, $reg_contactname); //Check If Added the product in Guest $chk_prf_guest = ChkPrdGuest(); if (count($chk_prf_guest) > 0) { //Check User Login $user_login = UserLogin($reg_email_id, $reg_password); if (count($user_login) > 0) { $_SESSION['sohorepro_userid'] = $user_login[0]['cus_id']; $_SESSION['sohorepro_companyid'] = $user_login[0]['cus_compname']; $_SESSION['sohorepro_username'] = $user_login[0]['cus_contact_name']; header("Location:shoppingcart.php?ref=" . $new_usr_ref); } else { echo 'Credentials In-Correct'; } } else { header("Location:existing_customer.php?new_user=succ&cus_id=" . $customer_id_new); } } if (isset($_REQUEST['new_company_add']) == '1') { extract($_POST); $comp_name_exist = checkcomp($reg_compname); if (count($comp_name_exist) > 0) {