aboutsummaryrefslogtreecommitdiffstats
path: root/boot.php
diff options
context:
space:
mode:
authorThomas Willingham <founder@kakste.com>2013-07-10 19:30:10 +0100
committerThomas Willingham <founder@kakste.com>2013-07-10 19:30:10 +0100
commit085be3a16f704a3f89bbe4d795c9ca915cc26e8a (patch)
treecd0a1b608630d5e819df221ed84a0fbd3755fc2f /boot.php
parentd065135d909bf876f4c305d303de7642657f7e3e (diff)
parent72d737cc82f5987791c9ceba0c8b99a505886274 (diff)
downloadvolse-hubzilla-085be3a16f704a3f89bbe4d795c9ca915cc26e8a.tar.gz
volse-hubzilla-085be3a16f704a3f89bbe4d795c9ca915cc26e8a.tar.bz2
volse-hubzilla-085be3a16f704a3f89bbe4d795c9ca915cc26e8a.zip
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'boot.php')
-rwxr-xr-xboot.php33
1 files changed, 32 insertions, 1 deletions
diff --git a/boot.php b/boot.php
index 32942bbce..a98cfdaf0 100755
--- a/boot.php
+++ b/boot.php
@@ -699,6 +699,8 @@ class App {
$this->is_mobile = $mobile_detect->isMobile();
$this->is_tablet = $mobile_detect->isTablet();
+ $this->head_set_icon('/images/rhash-32.png');
+
BaseObject::set_app($this);
/**
@@ -899,6 +901,7 @@ class App {
'$local_user' => local_user(),
'$generator' => RED_PLATFORM . ' ' . RED_VERSION,
'$update_interval' => $interval,
+ '$icon' => head_get_icon(),
'$head_css' => head_get_css(),
'$head_js' => head_get_js(),
'$js_strings' => js_strings()
@@ -997,6 +1000,17 @@ class App {
return $this->rdelim[$engine];
}
+ function head_set_icon($icon) {
+ $this->data['pageicon'] = $icon;
+
+ }
+
+ function head_get_icon() {
+ $icon = $this->data['pageicon'];
+ if(! strpos($icon,'://'))
+ $icon = z_root() . $icon;
+ return $icon;
+ }
}
@@ -1569,6 +1583,8 @@ function profile_sidebar($profile, $block = 0) {
return $o;
+ head_set_icon($profile['thumb']);
+
$is_owner = (($profile['uid'] == local_user()) ? true : false);
$profile['picdate'] = urlencode($profile['picdate']);
@@ -1930,7 +1946,7 @@ function current_theme(){
function current_theme_url($installing = false) {
global $a;
$t = current_theme();
- if((file_exists('view/theme/' . $t . '/php/style.php')) && (! $installing))
+ if(file_exists('view/theme/' . $t . '/php/style.php'))
return('view/theme/' . $t . '/php/style.pcss');
return('view/theme/' . $t . '/css/style.css');
}
@@ -2295,3 +2311,18 @@ function construct_page(&$a) {
function appdirpath() {
return dirname(__FILE__);
}
+
+
+function head_set_icon($icon) {
+ global $a;
+ $a->data['pageicon'] = $icon;
+ logger('head_set_icon: ' . $icon);
+}
+
+function head_get_icon() {
+ global $a;
+ $icon = $a->data['pageicon'];
+ if(! strpos($icon,'://'))
+ $icon = z_root() . $icon;
+ return $icon;
+}