diff options
Diffstat (limited to 'url.php')
-rw-r--r-- | url.php | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/url.php b/url.php new file mode 100644 index 0000000000..a9d0f58829 --- /dev/null +++ b/url.php @@ -0,0 +1,18 @@ +<?php +/** + * URL redirector to avoid leaking Referer with some sensitive information. + */ + +/** + * Gets core libraries and defines some variables + */ +require_once './libraries/common.inc.php'; + +PMA_checkParameters(array('url')); + +if (! preg_match('/^https?:\/\/[^\n\r]*$/', $GLOBALS['url'])) { + header('Location: ' . $cfg['PmaAbsoluteUri']); +} else { + header('Location: ' . $GLOBALS['url']); +} +?> |