aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--phpBB/includes/functions.php19
-rw-r--r--phpBB/includes/sessions.php23
2 files changed, 23 insertions, 19 deletions
diff --git a/phpBB/includes/functions.php b/phpBB/includes/functions.php
index 7777bc3a6f..9106c2c5ec 100644
--- a/phpBB/includes/functions.php
+++ b/phpBB/includes/functions.php
@@ -272,25 +272,6 @@ function create_date($format, $gmepoch, $tz)
}
//
-// Append $SID to a url
-// Borrowed from phplib
-// and modified
-//
-function append_sid($url)
-{
- global $SID;
-
- if(!empty($SID) && !eregi("^http:", $url) && !eregi("sid=", $url))
- {
- $url = ereg_replace("[&?]+$", "", $url);
- $url .= ( (strpos($url, "?") != false) ? "&" : "?" ) . $SID;
- }
-
- return($url);
-
-}
-
-//
// Pagination routine, generates
// page number sequence
//
diff --git a/phpBB/includes/sessions.php b/phpBB/includes/sessions.php
index 72f3d4fad6..c22abf1aad 100644
--- a/phpBB/includes/sessions.php
+++ b/phpBB/includes/sessions.php
@@ -463,4 +463,27 @@ function session_end($session_id, $user_id)
} // session_end()
+//
+// Append $SID to a url
+// Borrowed from phplib and modified. This is an
+// extra routine utilised by the session
+// code above and acts as a wrapper
+// around every single URL and form action. If
+// you replace the session code you must
+// include this routine, even if it's empty.
+//
+function append_sid($url)
+{
+ global $SID;
+
+ if(!empty($SID) && !eregi("^http:", $url) && !eregi("sid=", $url))
+ {
+ $url = ereg_replace("[&?]+$", "", $url);
+ $url .= ( (strpos($url, "?") != false) ? "&" : "?" ) . $SID;
+ }
+
+ return($url);
+
+}
+
?> \ No newline at end of file