diff options
author | friendica <info@friendica.com> | 2013-01-07 13:40:58 -0800 |
---|---|---|
committer | friendica <info@friendica.com> | 2013-01-07 13:40:58 -0800 |
commit | f04ce3b093c03fc343fce5b93e6ec6c7fd1ab214 (patch) | |
tree | f26e330f8dbeba32786e29d9634c6cc17f0c28a8 /mod | |
parent | 0001cc6fd38aaefa9bcabd1458b05ece855f3c67 (diff) | |
download | volse-hubzilla-f04ce3b093c03fc343fce5b93e6ec6c7fd1ab214.tar.gz volse-hubzilla-f04ce3b093c03fc343fce5b93e6ec6c7fd1ab214.tar.bz2 volse-hubzilla-f04ce3b093c03fc343fce5b93e6ec6c7fd1ab214.zip |
more work on notification system, fix a couple of minor issues from smarty conversion
Diffstat (limited to 'mod')
-rw-r--r-- | mod/channel.php | 17 | ||||
-rw-r--r-- | mod/hcard.php | 2 | ||||
-rw-r--r-- | mod/profile.php | 21 | ||||
-rw-r--r-- | mod/profile_photo.php | 4 | ||||
-rw-r--r-- | mod/profiles.php | 2 | ||||
-rw-r--r-- | mod/profperm.php | 2 | ||||
-rw-r--r-- | mod/viewcontacts.php | 2 |
7 files changed, 21 insertions, 29 deletions
diff --git a/mod/channel.php b/mod/channel.php index 096c76ae2..4510ad61d 100644 --- a/mod/channel.php +++ b/mod/channel.php @@ -32,13 +32,20 @@ function channel_aside(&$a) { require_once('include/contact_widgets.php'); require_once('include/items.php'); - profile_aside($a); - - $cat = ((x($_REQUEST,'cat')) ? htmlspecialchars($_REQUEST['cat']) : ''); + if(! $a->profile['profile_uid']) + return; - $a->set_widget('archive',posted_date_widget($a->get_baseurl(true) . '/channel/' . $a->profile['nickname'],$a->profile['profile_uid'],true)); - $a->set_widget('categories',categories_widget($a->get_baseurl(true) . '/channel/' . $a->profile['nickname'],$cat)); + $channel_display = get_pconfig($a->profile['profile_uid'],'system','channel_format'); + if(! $channel_display) + profile_create_sidebar($a); + if($channel_display === 'full') + $a->page['template'] = 'full'; + else { + $cat = ((x($_REQUEST,'cat')) ? htmlspecialchars($_REQUEST['cat']) : ''); + $a->set_widget('archive',posted_date_widget($a->get_baseurl(true) . '/channel/' . $a->profile['channel_address'],$a->profile['profile_uid'],true)); + $a->set_widget('categories',categories_widget($a->get_baseurl(true) . '/channel/' . $a->profile['channel_address'],$cat)); + } } diff --git a/mod/hcard.php b/mod/hcard.php index 83ae7c7af..ab2fa88a1 100644 --- a/mod/hcard.php +++ b/mod/hcard.php @@ -49,5 +49,5 @@ function hcard_init(&$a) { } function hcard_aside(&$a) { - profile_aside($a); + profile_create_sidebar($a); } diff --git a/mod/profile.php b/mod/profile.php index 8f15766b6..2f869a533 100644 --- a/mod/profile.php +++ b/mod/profile.php @@ -25,8 +25,8 @@ function profile_init(&$a) { ); if($x) { $a->profile = $x[0]; - $channel_display = get_pconfig($a->profile['profile_uid'],'system','channel_format'); - if(! $channel_display) +// $channel_display = get_pconfig($a->profile['profile_uid'],'system','channel_format'); +// if(! $channel_display) profile_load($a,$which,$profile); } @@ -38,22 +38,7 @@ function profile_aside(&$a) { require_once('include/contact_widgets.php'); require_once('include/items.php'); - $x = q("select channel_id as profile_uid from channel where channel_address = '%s' limit 1", - dbesc(argv(1)) - ); - if($x) { - $channel_display = get_pconfig($a->profile['profile_uid'],'system','channel_format'); - if(! $channel_display) - profile_aside($a); - - if($channel_display === 'full') - $a->page['template'] = 'full'; - else { - $cat = ((x($_REQUEST,'cat')) ? htmlspecialchars($_REQUEST['cat']) : ''); - $a->set_widget('archive',posted_date_widget($a->get_baseurl(true) . '/channel/' . $a->profile['nickname'],$a->profile['profile_uid'],true)); - $a->set_widget('categories',categories_widget($a->get_baseurl(true) . '/channel/' . $a->profile['nickname'],$cat)); - } - } + profile_create_sidebar($a); } diff --git a/mod/profile_photo.php b/mod/profile_photo.php index e7be543c6..d1e24269a 100644 --- a/mod/profile_photo.php +++ b/mod/profile_photo.php @@ -14,13 +14,13 @@ function profile_photo_init(&$a) { } -function profile_photo_init(&$a) { +function profile_photo_aside(&$a) { if(! local_user()) { return; } - profile_aside($a); + profile_create_sidebar($a); } diff --git a/mod/profiles.php b/mod/profiles.php index 5b2102852..12c86e3a2 100644 --- a/mod/profiles.php +++ b/mod/profiles.php @@ -153,7 +153,7 @@ function profiles_aside(&$a) { } if((argc() > 1) && (intval(argv(1)))) { - profile_aside($a); + profile_create_sidebar($a); } } diff --git a/mod/profperm.php b/mod/profperm.php index 7c7fe7b11..8054851e8 100644 --- a/mod/profperm.php +++ b/mod/profperm.php @@ -18,7 +18,7 @@ function profperm_aside(&$a) { if(! local_user()) return; - profile_aside($a); + profile_create_sidebar($a); } diff --git a/mod/viewcontacts.php b/mod/viewcontacts.php index 7f5050d5d..3f69e4a09 100644 --- a/mod/viewcontacts.php +++ b/mod/viewcontacts.php @@ -17,7 +17,7 @@ function viewcontacts_aside(&$a) { return; } - profile_aside($a); + profile_create_sidebar($a); } |