aboutsummaryrefslogtreecommitdiffstats
path: root/boot.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2013-01-03 15:52:05 -0800
committerfriendica <info@friendica.com>2013-01-03 15:52:05 -0800
commitf8bd476b882e95b8bdb589ae74645d030ef198fd (patch)
tree421266d618694160c7d8b088e1e78d74807cea70 /boot.php
parent7df33bb96366714116f8986f4a0a7d22f26729bf (diff)
downloadvolse-hubzilla-f8bd476b882e95b8bdb589ae74645d030ef198fd.tar.gz
volse-hubzilla-f8bd476b882e95b8bdb589ae74645d030ef198fd.tar.bz2
volse-hubzilla-f8bd476b882e95b8bdb589ae74645d030ef198fd.zip
import the toggle_mobile stuff to shut up some warnings
Diffstat (limited to 'boot.php')
-rw-r--r--boot.php16
1 files changed, 16 insertions, 0 deletions
diff --git a/boot.php b/boot.php
index d86b48436..fc93879e7 100644
--- a/boot.php
+++ b/boot.php
@@ -1924,3 +1924,19 @@ function dba_timer() {
return microtime(true);
}
+/**
+* Returns the complete URL of the current page, e.g.: http(s)://something.com/network
+*
+* Taken from http://webcheatsheet.com/php/get_current_page_url.php
+*/
+function curPageURL() {
+ $pageURL = 'http';
+ if ($_SERVER["HTTPS"] == "on") {$pageURL .= "s";}
+ $pageURL .= "://";
+ if ($_SERVER["SERVER_PORT"] != "80" && $_SERVER["SERVER_PORT"] != "443") {
+ $pageURL .= $_SERVER["SERVER_NAME"].":".$_SERVER["SERVER_PORT"].$_SERVER["REQUEST_URI"];
+ } else {
+ $pageURL .= $_SERVER["SERVER_NAME"].$_SERVER["REQUEST_URI"];
+ }
+ return $pageURL;
+}