From: Lo?c C. <lo...@us...> - 2001-04-13 10:26:27
|
Update of /cvsroot/phpmychat/phpMyChat-0.15/chat/lib/commands In directory usw-pr-cvs1:/tmp/cvs-serv23849/chat/lib/commands Modified Files: quit.cmd.php3 join.cmd.php3 Log Message: Improve the way users are logged out Index: quit.cmd.php3 =================================================================== RCS file: /cvsroot/phpmychat/phpMyChat-0.15/chat/lib/commands/quit.cmd.php3,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** quit.cmd.php3 2001/04/12 23:38:25 1.1 --- quit.cmd.php3 2001/04/13 10:26:25 1.2 *************** *** 62,98 **** */ dbSessionSave(); ! $exitQueryUrl = '?' . dbSessionSID('GET') . $GLOBALS['pmcQueryArgSeparator'] . 'exitMessage=1'; ! $jsExitUrl = $dbSessionVars['from'] . $exitQueryUrl; ! $htmlExitUrl = C_CHAT_URL . $exitQueryUrl; $dbLink->close(); ! ?> ! <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd"> ! <html> ! <head> ! <title>Exit whith the quit command</title> ! <script type="text/javascript" language="javascript"> ! <!-- ! // Close the loader ! if (window.parent.frames['loader'] && !window.parent.frames['loader'].closed) ! { ! if (typeof(window.parent.jsLeaveChat) != 'undefined') ! window.parent.jsLeaveChat = true; ! window.parent.frames['loader'].close(); ! } ! ! // Move to the start page ! window.parent.window.location = '<?php echo($jsExitUrl); ?>'; ! // --> ! </script> ! </head> ! <body> ! <!-- For browsers that do not support JavaScript --> ! <p> ! <a href="<?php echo($htmlExitUrl); ?>" target="_parent"><b><?php echo(C_CHAT_URL); ?></b></a> ! </p> ! </body> ! </html> ! ! <?php exit(); ?> --- 62,70 ---- */ dbSessionSave(); ! $exitUrl = $dbSessionVars['from'] ! . '?' . dbSessionSID('GET') ! . $GLOBALS['pmcQueryArgSeparator'] . 'exitMessage=1'; $dbLink->close(); ! require('./lib/move_to_start.lib.' . C_EXTENSION); exit(); ?> Index: join.cmd.php3 =================================================================== RCS file: /cvsroot/phpmychat/phpMyChat-0.15/chat/lib/commands/join.cmd.php3,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** join.cmd.php3 2001/04/12 23:38:25 1.1 --- join.cmd.php3 2001/04/13 10:26:25 1.2 *************** *** 159,198 **** else { ! $joinQueryUrl = '?' . dbSessionSID('GET') ! . $pmcQueryArgSeparator . 'exitMessage=1' ! . $pmcQueryArgSeparator . 'reloading=joinCmd' ! . $pmcQueryArgSeparator . 'newTargetRoom=' . $targetRoomType . urlencode($targetRoom); ! ! $jsJoinUrl = $dbSessionVars['from'] . $joinQueryUrl; ! $htmlJoinUrl = C_CHAT_URL . $joinQueryUrl; $dbLink->close(); ! ! ?> ! <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd"> ! <html> ! <head> ! <title>Exit from join command</title> ! <script type="text/javascript" language="javascript"> ! <!-- ! // Close the loader ! if (window.parent.frames['loader'] && !window.parent.frames['loader'].closed) ! { ! if (typeof(window.parent.jsLeaveChat) != 'undefined') ! window.parent.jsLeaveChat = true; ! window.parent.frames['loader'].close(); ! } ! ! window.parent.window.location = '<?php echo($jsJoinUrl); ?>'; ! // --> ! </script> ! </head> ! <body> ! <!-- For browsers that do not support JavaScript --> ! <p> ! <a href="<?php echo($htmlJoinUrl); ?>" target="_parent"><b><?php echo(C_CHAT_URL); ?></b></a> ! </p> ! </body> ! </html> ! <?php exit(); } --- 159,169 ---- else { ! $exitUrl = $dbSessionVars['from'] ! . '?' . dbSessionSID('GET') ! . $pmcQueryArgSeparator . 'exitMessage=1' ! . $pmcQueryArgSeparator . 'reloading=joinCmd' ! . $pmcQueryArgSeparator . 'newTargetRoom=' . $targetRoomType . urlencode($targetRoom); $dbLink->close(); ! include('./lib/move_to_start.lib.' . C_EXTENSION); exit(); } |