aboutsummaryrefslogtreecommitdiffstats
path: root/boot.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-12-06 00:03:24 -0800
committerfriendica <info@friendica.com>2012-12-06 00:03:24 -0800
commitc6b8ab534f4516605ed276b9f8677f9cf578ea45 (patch)
treed920a212cf7cbf583f87d874e47dc98abd271dd7 /boot.php
parentd715febf7c981f8b65fddb0952e769df56ba081f (diff)
downloadvolse-hubzilla-c6b8ab534f4516605ed276b9f8677f9cf578ea45.tar.gz
volse-hubzilla-c6b8ab534f4516605ed276b9f8677f9cf578ea45.tar.bz2
volse-hubzilla-c6b8ab534f4516605ed276b9f8677f9cf578ea45.zip
fixed several little nit bugs that cropped up during deployment
Diffstat (limited to 'boot.php')
-rw-r--r--boot.php18
1 files changed, 12 insertions, 6 deletions
diff --git a/boot.php b/boot.php
index 3d7401ba0..36fa535b1 100644
--- a/boot.php
+++ b/boot.php
@@ -626,6 +626,12 @@ if(! class_exists('App')) {
}
function set_baseurl($url) {
+
+ if(is_array($this->config) && array_key_exists('system',$this->config) &&
+ array_key_exists('baseurl',$this->config['system']) && strlen($this->config['system']['baseurl'])) {
+ $url = $a->config['system']['baseurl'];
+ }
+
$parsed = @parse_url($url);
$this->baseurl = $url;
@@ -860,13 +866,13 @@ function is_ajax() {
if(! function_exists('check_config')) {
- function check_config(&$a) {
+function check_config(&$a) {
$build = get_config('system','build');
if(! x($build))
$build = set_config('system','build',DB_UPDATE_VERSION);
- $url = get_config('system','url');
+// $url = get_config('system','baseurl');
// if the url isn't set or the stored url is radically different
// than the currently visited url, store the current value accordingly.
@@ -874,10 +880,10 @@ if(! function_exists('check_config')) {
// and www.example.com vs example.com.
// We will only change the url to an ip address if there is no existing setting
- if(! x($url))
- $url = set_config('system','url',$a->get_baseurl());
- if((! link_compare($url,$a->get_baseurl())) && (! preg_match("/^(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})$/",$a->get_hostname)))
- $url = set_config('system','url',$a->get_baseurl());
+// if(! x($url))
+// $url = set_config('system','baseurl',$a->get_baseurl());
+// if((! link_compare($url,$a->get_baseurl())) && (! preg_match("/^(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})$/",$a->get_hostname)))
+// $url = set_config('system','baseurl',$a->get_baseurl());