Esempio n. 1
0
    checkLogin_B4_Action();
}
switch ($ACTION) {
    case 'Logout':
        $MU = new ManageUsers();
        $MU->userId = $CURRENT_USERID;
        $MU->Logout_fromAllRooms();
        session_unset();
        session_destroy();
        send_Action_Response('Success', 'Logged Out!');
        exit;
        break;
    case 'doLogin':
        $uname = get_POST_var("uname");
        $uepwd = get_POST_var("uepwd");
        $emp_details = executesql_returnAssocArray("select * from tblAppUsers where BINARY emplUsername='******' and BINARY emplPassword='******' ");
        if (is_null($emp_details)) {
            session_unset();
            session_destroy();
            send_Action_Response('Fail', 'Invalid username or password !');
        }
        $_SESSION["uname"] = $uname;
        $_SESSION["empl_id"] = $emp_details['empl_id'];
        $_SESSION["emplEmail_id"] = $emp_details['emplEmail_id'];
        $_SESSION["emplFullName"] = $emp_details['emplFullName'];
        $_SESSION["emplLastLoginAt"] = $emp_details['emplLastLoginAt'];
        register_LastPingAt();
        send_Action_Response('Success', 'Logged In !');
        exit;
        break;
    case 'postmessage':
Esempio n. 2
0
 public function getChatFileUploadInfo($fileId)
 {
     //return executesql_returnAssocArray( " SELECT u.emplUsername as uploadedBy, cr.msgtime as uploadedDate FROM tbl_chatFiles cf, tbl_ChatRooms cr, tblAppUsers u  where cf.fileId = cr.fileId AND cf.fileId='$fileId' AND cr.saidBy_empl_id = u.empl_id " );
     return executesql_returnAssocArray(" SELECT u.emplUsername as uploadedBy, cr.msgtime as uploadedDate, r.roomId as roomId  FROM tbl_chatFiles cf, tbl_ChatRooms cr, tblAppUsers u, tblRooms r  where cf.fileId = cr.fileId AND cf.fileId='{$fileId}' AND cr.saidBy_empl_id = u.empl_id AND r.roomId=cr.chatRoom ");
 }
Esempio n. 3
0
 public function get_workDetails($workID)
 {
     return executesql_returnAssocArray("select `work_userAssigned`, `work_addedBy`, `work_dateAdded`, `work_deadLine`, `work_startDate`, `work_completeDate`, `work_briefDesc`, `work_Notes`, `work_status`, `work_priority`, `work_projectName`, `work_isPrivate` from WORKS where workID='{$workID}' ");
 }
Esempio n. 4
0
<?php

include_once "include_db.php";
$CUSTOM_STYLES = "\n\t#pwdTitleRow{\n\tfont-size: 15px;\n\tfont-weight : bold ;\n\tcolor : #718DA1;\n\t}\n\n\tspan.bluebuttonSmall , div.bluebuttonSmall {\n\tbackground-color: #EBE9E9;\n\tborder: 1px outset #B6C7E5;\n\tcolor: #445A80;\n\tline-height: 1.4em;\n\tpadding: 2px 4px;\n\tcursor: pointer;\n\tfont-size: 85%;\n\t}\n";
include_once "include_functions.php";
include_once "include_header.php";
//include_once "include_header_links.php";
if (get_GET_var('id')) {
    $id = get_GET_var('id');
    $key = get_GET_var('key');
    $invi_Id = $id;
    $sql = "SELECT * FROM tbl_Invitations WHERE invi_Id='{$invi_Id}' AND invi_key='{$key}'";
    $invi_details = executesql_returnAssocArray($sql);
    $invi_sent_by = $invi_details['invi_sent_by'];
    $userFName = executesql_returnArray("select emplFullName from tblAppUsers where emplUsername='******'");
    if ($invi_details['invi_status'] != '0') {
        echo "Invalid Invitation. May be the invitation already used.";
        exit;
    }
} else {
    echo "Invalid Invitation. May be the invitation already used.";
    exit;
}
?>
<script>
	
	var localajaxinit = function(){
		
	};

	var checkInvitation = function(){