function save_passwod_key($Key, $LoginID) { $currentTime = time(); $validUpto = $currentTime + 86400; $SQL = "INSERT INTO `vcc_resetpassword`(`LoginID`,`UniqueKey`,`RequestDate`,`ValidUpto`) VALUES(" . $LoginID . ",'" . $Key . "'," . $currentTime . "," . $validUpto . ");"; eii($SQL); }
function func_add_new_npdetails($R) { $LonAndLat = curlGeoInformation($R[nppcAddress], $R[nppcCity], $R[nppcState]); $SQL = "INSERT INTO `nonprofit`(" . "`NPjobCode`,`NonProfit`,`doNotCall`,`NPFirst`,`NPLast`,`NPAddress`," . "`NPCity`,`NPState`,`NPZip`,`latitude`,`longitude`,`NPPhone`,`NPPhoneExt`,`NPFax`,`NPEmail`," . "`NPsecondayrFirst`,`NPsecondaryLast`,`NPsecondaryPhone`,`NPsecondaryExt`,`NPsecondaryEmail`," . "`schedule1`,`schedule2`,`schedule3`,`np2Name`,`np2CompAddress`,`totalWeeklyHours`,`dressCode`," . "`NPdescription`,`NPaddInfo`,`status`) "; $SQL .= " VALUES('{$R['npJobCode']}','{$R['npNonProfit']}','{$R['npDndCall']}','" . htmlentities($R[nppcFirstName]) . "'," . "'" . htmlentities($R[nppcLastName]) . "','" . htmlentities($R[nppcAddress]) . "','{$R['nppcCity']}','{$R['nppcState']}'," . "'{$R['nppcZip']}','" . $LonAndLat[0]['lat'] . "','" . $LonAndLat[0]['lon'] . "','{$R['nppcPhone']}','{$R['nppcExtension']}'," . "'{$R['nppcFax']}','{$R['nppcEmail']}','" . htmlentities($R[npscFirstName]) . "','" . htmlentities($R[npscLastName]) . "'," . "'{$R['sPhone']}','{$R['sExtension']}','{$R['sEmail']}','{$R['npwsWorkSchedule1']}','{$R['npwsWorkSchedule2']}'," . "'{$R['npwsWorkSchedule3']}','" . htmlentities($R[np2Name]) . "','" . htmlentities($R[np2AddrComb]) . "'," . "'{$R['npwsTotalWeeklyHours']}','{$R['npDressCode']}','{$R['npDescription']}','{$R['npAddnInst']}','{$R['npwsStatus']}');"; return $NonProfitID = eii($SQL); }
function assign_mail() { global $SERVER_PATH, $SignIN; $R = DIN_ALL($_REQUEST); if (($_SESSION['UserID'] <= 0 || $_SESSION['UserID'] == "") && $_SESSION['http_agent'] != $_SERVER['HTTP_USER_AGENT']) { header("Location:" . $SignIN); die; } else { if (intval($R['PersonID']) > 0 && intval($R['EmployeeID']) > 0) { $Query = "UPDATE vcc_iemployee SET PersonAssignedID = {$R['PersonID']},PresetContentID = {$R['PresetContentID']} WHERE IEmployeeID = " . $R['EmployeeID']; eqi($Query, $rs); if (get_row_con_info("vcc_initials VCI LEFT JOIN vcc_iemployee VCE ON VCE.PersonAssignedID = VCI.InitialID LEFT JOIN vcc_placement_status VPS ON VCE.PresetContentID = VPS.PlacementID", "WHERE VCE.IEmployeeID = {$R['EmployeeID']}", "VCCCaseNumber,Placement,IFirstName,ILastName,FullName,EmailAddress", $Initials)) { $subject = "New VCC Referral VCC Case # : " . $Initials[VCCCaseNumber]; $message = "You have been assigned a new referral VCC Case # : " . $Initials[VCCCaseNumber] . " for Employee {$Initials['ILastName']},{$Initials['IFirstName']} with {$Initials['Placement']}"; send_mail_new($Initials[FullName], $Initials[EmailAddress], "VARNER CLAIMS CONSULTING", "*****@*****.**", $subject, $message, "", "", "", "*****@*****.**"); $sqlQuery = "INSERT INTO vcc_notes(\n `InitialID`,\n `NoteDescription`,\n `EmployeeID`,\n `CreatedDate`)\n VALUES(\n\t\t\t\t\t\t\t\t\t (SELECT InitialID FROM vcc_initials WHERE LoginID={$_SESSION['UserID']}),'{$Initials['EmailAddress']} has been assigned for VCC Case # : {$Initials['VCCCaseNumber']} with {$Initials['Placement']}',{$R['EmployeeID']},NOW());"; eii($sqlQuery); echo "mail sent"; } } else { echo "select an appropriate value"; } } }