diff --git a/ag/ag_popupchat.php b/ag/ag_popupchat.php index c2ad625..84285c3 100644 --- a/ag/ag_popupchat.php +++ b/ag/ag_popupchat.php @@ -11,6 +11,10 @@ $nodisturb = 'YES'; include_once('path.inc.php'); // get the path ;) include_once (ROOT_PATH . '/include/config.inc.php'); include_once (ROOT_PATH . '/include/messagefunctions.inc.php'); +include_once (ROOT_PATH . '/include/defines.inc.php'); + +defineIfNotDefined('AG_CHAT_ROWS', 25); +defineIfNotDefined('AG_CHAT_ORDER', 'ASC'); // Die Nachricht muss nicht geparst werden! @@ -69,9 +73,9 @@ if (isset($_GET['send'])) { header("Cache-Control: no-store, no-cache, must-revalidate"); header("Cache-Control: post-check=0, pre-check=0", false); header("Pragma: no-cache"); - echo getChatMessages($user_ida['id'], $_GET['id']); + echo getChatMessages($user_ida['id'], $_GET['id'], AG_CHAT_ORDER=='ASC'?TRUE:FALSE, AG_CHAT_ROWS); } else { - $messagearray = getChatMessages($user_ida['id']); + $messagearray = getChatMessages($user_ida['id'], null, AG_CHAT_ORDER=='ASC'?TRUE:FALSE, AG_CHAT_ROWS); $delay = 6500; // 6.5 Sekunden $activeTime = 30; // 30 Min @@ -84,9 +88,18 @@ if (isset($_GET['send'])) { + + +
+ + +