src/Conversation.php 1 location
|
@@ 58-61 (lines=4) @@
|
| 55 |
|
$login_id = (int)$fetch['login_id']; |
| 56 |
|
|
| 57 |
|
// Unique Identifier |
| 58 |
|
if($login_id > $userId) |
| 59 |
|
$identifier = $userId.':'.$login_id; |
| 60 |
|
else |
| 61 |
|
$identifier = $login_id.':'.$userId; |
| 62 |
|
|
| 63 |
|
$query = "SELECT total_messages from total_message where identifier = '$identifier'"; |
| 64 |
|
if($result = $this->connect->query($query)) |
src/Reply.php 1 location
|
@@ 42-45 (lines=4) @@
|
| 39 |
|
|
| 40 |
|
$receiverID = $identifier; //stores id of the person whom message is to be sent |
| 41 |
|
|
| 42 |
|
if($identifier > $userId) // geneate specific unique code to store messages |
| 43 |
|
$identifier = $userId . ":" . $identifier; |
| 44 |
|
else |
| 45 |
|
$identifier = $identifier . ":" . $userId; |
| 46 |
|
|
| 47 |
|
$reply = addslashes(trim($msg->reply[0])); // stores the message sent by the user. |
| 48 |
|
|