Exemplo n.º 1
0
<?php

include_once "model/GenericTable.php";
include_once "header.php";
if (isset($_POST)) {
    $location = $_POST['location'];
    $status = $_POST['status'];
    $otablefeedback = new GenericTable($dbh, 'fb_location');
    if ($status == 'Y') {
        $disable = 'N';
    } else {
        $disable = 'Y';
    }
    $list = array('DISABLE' => $disable);
    $clause = "where LOCID='{$location}'";
    $otablefeedback->updateRow($list, $clause);
    echo "true";
}
Exemplo n.º 2
0
    $name = $_POST['name'];
    $mobile = $_POST['mobile'];
    $email = $_POST['email'];
    $dob = $_POST['dob'];
    $age = $_POST['age'];
    $iam = $_POST['radios'];
    if ($iam == "others") {
        $iam = $_POST['other'];
    }
    $interest = implode(",", $_POST['interested']);
    $currently = implode(",", $_POST['chk']);
    $chkother = $_POST['chkother'];
    $sales_radios = $_POST['sales_radios'];
    $customer_radios = $_POST['customer_radios'];
    $knownby = $_POST['knowby'];
    $appreciate = $_POST['appreciate'];
    $serve = $_POST['serve'];
    $otablefeedback = new GenericTable($dbh, 'fb_feedback');
    $list = array('userid' => $userid, 'locid' => $locid, 'title' => $title, 'name' => $name, 'mobile' => $mobile, 'mailid' => $email, 'dob' => $dob, 'age' => $age, 'designation' => $iam, 'interest' => $interest, 'currently' => $currently, 'currentlyothers' => $chkother, 'salepro' => $sales_radios, 'customerexp' => $customer_radios, 'knownby' => $knownby, 'appreciate' => $appreciate, 'serveby' => $serve, 'timestamp' => time());
    $id = $otablefeedback->insertRow($list);
    $fid = 'FB' . $instance_identifier . $id;
    $hashid = md5($fid . $name . $mobile);
    $updatelist = array('FBID' => $fid, 'HASHID' => $hashid);
    $clause = "where ID='{$id}'";
    $otablefeedback->updateRow($updatelist, $clause);
}
?>
<script type="text/javascript">
	alert("Thanks For Your feedback");
    window.location.href = "index.php"; 
</script>
Exemplo n.º 3
0
<?php

include_once "model/GenericTable.php";
include_once "header.php";
if (isset($_POST)) {
    $userid = $_POST['userid'];
    $status = $_POST['status'];
    $otableUserDetails = new GenericTable($dbh, 'fb_userdetails');
    if ($status == 'Y') {
        $disable = 'N';
    } else {
        $disable = 'Y';
    }
    $list = array('DISABLE' => $disable);
    $clause = "where USERID='{$userid}'";
    $otableUserDetails->updateRow($list, $clause);
    echo "true";
}
Exemplo n.º 4
0
<?php

include_once "model/GenericTable.php";
include_once "header.php";
function random_password($length = 8)
{
    $chars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!@#\$%^&*()_-=+;:,.?";
    $password = substr(str_shuffle($chars), 0, $length);
    return $password;
}
if (isset($_POST)) {
    $location = $_POST['location'];
    $mailid = $_POST['mailid'];
    $otableuser = new GenericTable($dbh, 'fb_userdetails');
    $otablepassword = new GenericTable($dbh, 'fb_password');
    $pass = random_password(8);
    $password = md5($pass);
    $updatelist = array('password' => $password, 'changepassword' => 'Y');
    $clause = "where location='{$location}'";
    $otableuser->updateRow($updatelist, $clause);
    $plist = array('LOCNAME' => $location, 'EMAIL' => $mailid, 'PASSWORD' => $pass, 'TIMESTAMP' => time());
    $otablepassword->insertRow($plist);
    //Email Header
    $emailheader = "From: ikure <*****@*****.**>\r\nContent-type: text/html";
    $to = $mailid;
    $subject = "Password Reset";
    $txt = "Your account password has been reset to the following password.<BR/> Password: "******"text/javascript">
				alert("Your password has been send to registered mail id.");
Exemplo n.º 5
0
<?php

include_once "model/GenericTable.php";
include_once "header.php";
if (isset($_POST)) {
    $locid = $_POST['locid'];
    $username = $_POST['username'];
    $newpassword = $_POST['newpassword'];
    $otableuser = new GenericTable($dbh, 'fb_userdetails');
    $updatelist = array('password' => md5($newpassword), 'changepassword' => 'N');
    $clause = "where location='{$locid}' and username='******'";
    $otableuser->updateRow($updatelist, $clause);
}
?>
<script type="text/javascript">
	alert("Your password has been changed successfully.");
    window.location.href = "login.php"; 
</script>