# HG changeset patch # User Nathan Phillip Brink # Date 2012-02-19 01:21:32 # Node ID 6e11d567188ae94fa3f28f6e43c7549f6b823db7 # Parent 46201cc47146ac1e7f941f08f18142a8eb934f73 Add support for manually specifying the base_uri. This is necessary for me to continue developing on my messed up mpm_peruser installation of slate_permutate since my apache's idea of its hostname is wrong. diff --git a/inc/class.page.php b/inc/class.page.php --- a/inc/class.page.php +++ b/inc/class.page.php @@ -41,6 +41,7 @@ set_include_path(get_include_path() . PA * sense soon. */ /* defaults */ +$base_uri = ''; $clean_urls = FALSE; $ga_trackers = array(); $ga_conversions = array(); @@ -697,7 +698,7 @@ class page */ public static function uri_resolve($uri = '') { - static $base_uri = ''; + global $base_uri; static $host = ''; if (empty($host)) diff --git a/inc/config.inc.example b/inc/config.inc.example --- a/inc/config.inc.example +++ b/inc/config.inc.example @@ -42,6 +42,12 @@ /** * \brief + * Specify the base URI if Slate Permutate's auto-detection doesn't work. + */ +/* $base_uri = 'http://example.com/slate_permutate/'; */ + +/** + * \brief * Custom clean URLs for schedule sharing. $clean_urls must be enabled. * * This string should be set to a valid base URL that is rewritten