remove old readme
[atutor.git] / docs / mods / _standard / chat / bing.php
1 <?php
2 /****************************************************************/
3 /* ATutor                                                                                                               */
4 /****************************************************************/
5 /* Copyright (c) 2002-2010                                      */
6 /* Inclusive Design Institute                                   */
7 /* http://atutor.ca                                                                                             */
8 /*                                                              */
9 /* This program is free software. You can redistribute it and/or*/
10 /* modify it under the terms of the GNU General Public License  */
11 /* as published by the Free Software Foundation.                                */
12 /****************************************************************/
13
14 define('AT_INCLUDE_PATH', '../include/');
15
16         require(AT_INCLUDE_PATH.'vitals.inc.php');
17 require(AT_INCLUDE_PATH.'lib/chat.inc.php');
18         $chatID  = $_GET['chatID'];
19         $uniqueID= intval($_GET['uniqueID']);
20
21         $myPrefs = getPrefs($_GET['chatID']);
22
23         howManyMessages(&$topMsgNum, &$bottomMsgNum);
24         if ($myPrefs['lastChecked'] < $topMsgNum && $myPrefs['lastRead'] < $topMsgNum) {
25                 $myPrefs['lastChecked'] = $topMsgNum;
26                 writePrefs($myPrefs, $chatID);
27                 print "yes\n";
28         }
29         print "$topMsgNum $myPrefs[lastChecked] $myPrefs[lastRead] \n";
30 ?>