/* * -------------------------- * Require/Include Files * ------------------------- */ require_once '../../class_ajax_request/classAjax.php'; include_once '../../application/functions.php'; include_once '../../application/DataConfig.php'; /* * ---------------------- * Instance Class * ---------------------- */ $obj = new AjaxRequest(); $infoUser = $obj->infoUserLive($_SESSION['authenticated']); $response = $obj->getMessages($_SESSION['authenticated'], ' && id ' . $query . ' ' . $offset . '', null); ?> <?php $countPosts = count($response); if ($countPosts != 0) { foreach ($response as $key) { if ($key['from'] == $_SESSION['authenticated'] && $key['username'] == $infoUser->username) { $key['name'] = $key['name2']; $key['username'] = $key['username2']; $key['avatar'] = $key['avatar2']; $key['type_account'] = $key['type_account2']; $ID = $key['id_2']; $sendTo = '<i class="icon-undo2"></i> '; } else { if ($key['from'] == $_SESSION['authenticated'] && $key['username2'] == $infoUser->username) { $key['name'] = $key['name'];