|
From: Paul S. O. <ps...@us...> - 2001-10-14 15:49:55
|
Update of /cvsroot/phpbb/phpBB2
In directory usw-pr-cvs1:/tmp/cvs-serv14869
Modified Files:
posting.php viewtopic.php login.php
Log Message:
Various updates mainly URI session related ... login still having problem with full URI sessions
Index: posting.php
===================================================================
RCS file: /cvsroot/phpbb/phpBB2/posting.php,v
retrieving revision 1.77
retrieving revision 1.78
diff -C2 -r1.77 -r1.78
*** posting.php 2001/10/10 14:57:52 1.77
--- posting.php 2001/10/14 15:49:52 1.78
***************
*** 849,853 ****
//
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=viewtopic.' . $phpEx . '?' . POST_POST_URL . '=' . $new_post_id .'#' . $new_post_id . '">')
);
--- 849,853 ----
//
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewtopic.$phpEx?" . POST_POST_URL . "=$new_post_id") . '#' . $new_post_id . '">')
);
***************
*** 989,993 ****
{
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=viewtopic.' . $phpEx . '?' . POST_TOPIC_URL . '=' . $topic_id . '">')
);
--- 989,993 ----
{
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id") . '">')
);
***************
*** 1164,1168 ****
{
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=viewtopic.' . $phpEx . '?' . POST_TOPIC_URL . '=' . $topic_id . '">')
);
--- 1164,1168 ----
{
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url= ' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id") . '">')
);
***************
*** 1172,1176 ****
{
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=viewforum.' . $phpEx . '?' . POST_FORUM_URL . '=' . $forum_id . '">')
);
}
--- 1172,1176 ----
{
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewforum.$phpEx?" . POST_FORUM_URL . "=$forum_id") . '">')
);
}
***************
*** 1374,1378 ****
//
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=viewtopic.' . $phpEx . '?' . POST_POST_URL . '=' . $post_id . '#' . $post_id . '">')
);
--- 1374,1378 ----
//
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewtopic.$phpEx?" . POST_POST_URL . "=$post_id") . '#' . $post_id . '">')
);
***************
*** 1399,1403 ****
//
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=viewtopic.' . $phpEx . '?' . POST_POST_URL . '=' . $post_id . '#' . $post_id . '">')
);
--- 1399,1403 ----
//
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewtopic.$phpEx?" . POST_POST_URL . "=$post_id") . '#' . $post_id . '">')
);
***************
*** 1445,1449 ****
{
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=viewtopic.' . $phpEx . '?' . POST_TOPIC_URL . '=' . $topic_id . '">')
);
--- 1445,1449 ----
{
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "= $topic_id") . '">')
);
***************
*** 1480,1484 ****
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=viewtopic.' . $phpEx . '?' . POST_TOPIC_URL . '=' . $topic_id . '">')
);
--- 1480,1484 ----
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id") . '">')
);
***************
*** 1509,1513 ****
{
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=viewtopic.' . $phpEx . '?' . POST_TOPIC_URL . '=' . $topic_id . '">')
);
--- 1509,1513 ----
{
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id") . '">')
);
***************
*** 2107,2110 ****
--- 2107,2112 ----
"L_NOTIFY_ON_REPLY" => $lang['Notify'],
"L_DELETE_POST" => $lang['Delete_post'],
+
+ "U_TOPIC_REVIEW" => ( $mode == "reply" ) ? append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&postorder=desc") : "",
"S_HTML_CHECKED" => (!$html_on) ? "checked=\"checked\"" : "",
Index: viewtopic.php
===================================================================
RCS file: /cvsroot/phpbb/phpBB2/viewtopic.php,v
retrieving revision 1.118
retrieving revision 1.119
diff -C2 -r1.118 -r1.119
*** viewtopic.php 2001/10/11 22:01:10 1.118
--- viewtopic.php 2001/10/14 15:49:52 1.119
***************
*** 236,243 ****
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=viewtopic.' . $phpEx . '?' . POST_TOPIC_URL . '=' . $topic_id . '&start=' . $start .'">')
);
! $message = $lang['No_longer_watching']. "<br /><br />" . $lang['Click'] . " <a href=\"viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&start=$start\">" . $lang['HERE'] . "</a> " . $lang['to_return_topic'];
message_die(GENERAL_MESSAGE, $message);
}
--- 236,243 ----
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&start=$start") . '">')
);
! $message = $lang['No_longer_watching']. "<br /><br />" . $lang['Click'] . " <a href=\"" . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&start=$start") . "\">" . $lang['Here'] . "</a> " . $lang['to_return_topic'];
message_die(GENERAL_MESSAGE, $message);
}
***************
*** 280,287 ****
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=viewtopic.' . $phpEx . '?' . POST_TOPIC_URL . '=' . $topic_id . '&start=' . $start .'">')
);
! $message = $lang['You_are_watching']. "<br /><br />" . $lang['Click'] . " <a href=\"viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&start=$start\">" . $lang['HERE'] . "</a> " . $lang['to_return_topic'];
message_die(GENERAL_MESSAGE, $message);
}
--- 280,287 ----
$template->assign_vars(array(
! "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&start=$start") . '">')
);
! $message = $lang['You_are_watching']. "<br /><br />" . $lang['Click'] . " <a href=\"" . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&start=$start") . "\">" . $lang['Here'] . "</a> " . $lang['to_return_topic'];
message_die(GENERAL_MESSAGE, $message);
}
***************
*** 298,302 ****
if( $HTTP_GET_VARS['unwatch'] == "topic" )
{
! header("Location: login.$phpEx?forward_page=viewtopic.$phpEx&" . POST_TOPIC_URL . "=$topic_id&unwatch=topic");
}
}
--- 298,302 ----
if( $HTTP_GET_VARS['unwatch'] == "topic" )
{
! header("Location: " . append_sid("login.$phpEx?forward_page=viewtopic.$phpEx&" . POST_TOPIC_URL . "=$topic_id&unwatch=topic"));
}
}
Index: login.php
===================================================================
RCS file: /cvsroot/phpbb/phpBB2/login.php,v
retrieving revision 1.28
retrieving revision 1.29
diff -C2 -r1.28 -r1.29
*** login.php 2001/10/10 20:28:45 1.28
--- login.php 2001/10/14 15:49:52 1.29
***************
*** 34,45 ****
//
! if(isset($HTTP_POST_VARS['submit']) || isset($HTTP_GET_VARS['submit']))
{
! if($HTTP_POST_VARS['submit'] == "Login" && !$userdata['session_logged_in'])
{
- $username = $HTTP_POST_VARS['username'];
- $password = $HTTP_POST_VARS['password'];
-
$sql = "SELECT user_id, username, user_password, user_active
FROM ".USERS_TABLE."
--- 34,44 ----
//
! if( isset($HTTP_POST_VARS['login']) || isset($HTTP_GET_VARS['login']) || isset($HTTP_POST_VARS['logout']) || isset($HTTP_GET_VARS['logout']) )
{
! if( ( isset($HTTP_POST_VARS['login']) || isset($HTTP_GET_VARS['login']) ) && !$userdata['session_logged_in'] )
{
+ $username = isset($HTTP_POST_VARS['username']) ? $HTTP_POST_VARS['username'] : "";
+ $password = isset($HTTP_POST_VARS['password']) ? $HTTP_POST_VARS['password'] : "";
$sql = "SELECT user_id, username, user_password, user_active
FROM ".USERS_TABLE."
***************
*** 62,68 ****
if($session_id)
{
! if(!empty($HTTP_POST_VARS['forward_page']))
{
! header("Location: " . append_sid($HTTP_POST_VARS['forward_page']));
}
else
--- 61,68 ----
if($session_id)
{
! if( !empty($HTTP_POST_VARS['forward_page']) )
{
! // echo $HTTP_POST_VARS['forward_page'];
! header("Location: " . $HTTP_POST_VARS['forward_page']);
}
else
***************
*** 86,96 ****
}
}
! else if($HTTP_GET_VARS['submit'] == "logout" && $userdata['session_logged_in'])
{
! if($userdata['session_logged_in'])
{
session_end($userdata['session_id'], $userdata['user_id']);
}
! if(!empty($HTTP_POST_VARS['forward_page']))
{
header("Location: " . append_sid($HTTP_POST_VARS['forward_page']));
--- 86,96 ----
}
}
! else if( ( isset($HTTP_GET_VARS['logout']) || isset($HTTP_POST_VARS['logout']) ) && $userdata['session_logged_in'] )
{
! if( $userdata['session_logged_in'] )
{
session_end($userdata['session_id'], $userdata['user_id']);
}
! if( !empty($HTTP_POST_VARS['forward_page']) )
{
header("Location: " . append_sid($HTTP_POST_VARS['forward_page']));
***************
*** 103,107 ****
else
{
! if(!empty($HTTP_POST_VARS['forward_page']))
{
header(append_sid("Location: ".$HTTP_POST_VARS['forward_page']));
--- 103,107 ----
else
{
! if( !empty($HTTP_POST_VARS['forward_page']) )
{
header(append_sid("Location: ".$HTTP_POST_VARS['forward_page']));
***************
*** 128,136 ****
);
! if(isset($HTTP_POST_VARS['forward_page']) || isset($HTTP_GET_VARS['forward_page']))
{
! $forward_to = $HTTP_SERVER_VARS['QUERY_STRING'];
! if(preg_match("/^forward_page=(.*)(&sid=[0-9]*)$|^forward_page=(.*)$/si", $forward_to, $forward_matches))
{
$forward_to = ($forward_matches[3]) ? $forward_matches[3] : $forward_matches[1];
--- 128,136 ----
);
! if( isset($HTTP_POST_VARS['forward_page']) || isset($HTTP_GET_VARS['forward_page']) )
{
! echo $forward_to = $HTTP_SERVER_VARS['QUERY_STRING'];
! if( preg_match("/^forward_page=(.*)(&sid=[0-9]*)$|^forward_page=(.*)$/si", $forward_to, $forward_matches) )
{
$forward_to = ($forward_matches[3]) ? $forward_matches[3] : $forward_matches[1];
|