remove old readme
[atutor.git] / docs / mods / _standard / chat / logout.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         require(AT_INCLUDE_PATH.'vitals.inc.php');
16         session_write_close();
17         //authenticate(USER_CLIENT, USER_ADMIN);
18         require(AT_INCLUDE_PATH.'../mods/_standard/chat/lib/chat.inc.php');
19
20         $myPrefs = getPrefs($_SESSION['login']);
21
22
23         $topMsgNum = $bottomMsgNum = 0;
24     howManyMessages($topMsgNum, $bottomMsgNum);
25         postMessage(_AT('chat_system'),
26                                 _AT('chat_logged_out', $_SESSION['login']),
27                                 $topMsgNum,
28                                 $bottomMsgNum);
29
30         $myPrefs['lastAccessed'] = 0;
31         writePrefs($myPrefs, $_SESSION['login']);
32
33         Header('Location: index.php');
34         exit;
35         //exit;
36 require('include/html/chat_header.inc.php');
37 ?>
38 <table width="100%" border="0" cellpadding="5" cellspacing="0">
39 <tr>
40         <td align="left"><h4><?php echo $admin['chatName']; ?>: Logout</h4></td>
41 </tr>
42 </table>
43
44 <p>The <?php echo $admin['chatName']; ?> will automatically save an account for you so that the next time you login with your <strong>Chat ID</strong> and <strong>Password</strong> your <strong>Preference Settings</strong> will be reloaded.</p>
45
46 <p align="center"><b>Thank you for using the <?php echo $admin['chatName']; ?>.<br />
47 <a href="http://www.utoronto.ca/atrc/" target="_new" onFocus="this.className='highlight'" onBlur="this.className=''"><img src="chat/atrc.gif" border="0" /></a></p>
48
49
50 <table width="100%" border="0" cellpadding="5" cellspacing="0">
51 <tr> 
52         <td align="right"><a href="chat/index.php" onFocus="this.className='highlight'" onBlur="this.className=''">Re-enter Chat</a></td>
53 </tr>
54 </table>
55 <?php
56         require('include/html/chat_footer.inc.php');
57 ?>