aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/apps.php15
1 files changed, 14 insertions, 1 deletions
diff --git a/include/apps.php b/include/apps.php
index 38812ef83..244c2adb7 100644
--- a/include/apps.php
+++ b/include/apps.php
@@ -40,14 +40,27 @@ function get_system_apps() {
function parse_app_description($f) {
$ret = array();
+ $baseurl = z_root();
+ $channel = get_app()->get_channel();
+ $address = (($channel) ? $channel['channel_address'] : '');
+
+ //future expansion
+
+ $observer = get_observer();
+
+
+
$lines = @file($f);
if($lines) {
foreach($lines as $x) {
if(preg_match('/^([a-zA-Z].*?):(.*?)$/ism',$x,$matches)) {
- $ret[$matches[1]] = trim($matches[2]);
+ $ret[$matches[1]] = trim(str_replace(array('$baseurl','$nick'),array($baseurl,$address),$matches[2]));
}
}
}
+ if(! $ret['photo'])
+ $ret['photo'] = $baseurl . '/' . get_default_profile_photo(80);
+
return $ret;
}