File manager - Edit - /home/autoph/public_html/pms_v1/notify/viewMsgThread.php
Back
<?php include_once("../../../cfg/conn.php"); error_reporting(0); if(isset($_POST['vMsg'])){ $userID=$_POST['userID']; $messageID=$_POST['messageID']; //GET ASSIGNED TOKEN $getToken = "SELECT * FROM `pms_inbox` WHERE id = '$messageID' ORDER BY `id` ASC LIMIT 1 "; $getT = mysqli_query($conn,$getToken); while($row = mysqli_fetch_array($getT)){ $myToken=$row['group_msg_id']; } $getThread = "SELECT * FROM `pms_inbox` WHERE `deleted`=0 AND `group_msg_id`='$myToken' ORDER BY `id` ASC "; $getTH = mysqli_query($conn,$getThread); while($rows = mysqli_fetch_array($getTH)){ $senderID = $rows['sender_id']; if($senderID == $userID){ $tAlign='right'; $bgColor='#F6FDE5'; }else{ $tAlign='left'; $bgColor='#F7F9F4'; } echo "<div style='width:100%;padding:10px;text-align:$tAlign;box-shadow:3px 3px 3px lightgray;background:$bgColor;margin-bottom:10px'>"; $getSenderData = "SELECT * FROM `pms_employee_data` WHERE `id`='$senderID' LIMIT 1"; $getEData = mysqli_query($conn,$getSenderData); while($row=mysqli_fetch_array($getEData)){ $fName = $row['last_name'].", "; $lName = $row['first_name']; } echo "<h6 style='text-align:$tAlign;padding:2px;margin-bottom:5px;font-family:Calibri;font-size:12px;'>Sender: ".$lName. ", ".$fName."</h6>"; echo "<h6 style='text-align:$tAlign;padding:2px;margin:5px;font-family:calibri;font-size:14px;'>".$rows['message']."</h6>"; echo "<h6 style='text-align:$tAlign;padding:2px;margin-bottom:3px;font-family:Calibri;font-size:12px;'>Date Received: ".$rows['date_time']."</h6>"; echo "</div>"; } $conn->close(); } ?>
| ver. 1.4 |
.
| PHP 7.3.33 | Generation time: 0 |
proxy
|
phpinfo
|
Settings