don't show diaspora protocol info in the hcard if the diaspora protocol is not installed. This really needs to be moved to the plugin but this was a quick fix.
This commit is contained in:
parent
10863a5949
commit
134b9fc466
@ -1066,6 +1066,9 @@ function profile_sidebar($profile, $block = 0, $show_connect = true, $zcard = fa
|
|||||||
? trim(substr($profile['channel_name'],0,strpos($profile['channel_name'],' '))) : $profile['channel_name']);
|
? trim(substr($profile['channel_name'],0,strpos($profile['channel_name'],' '))) : $profile['channel_name']);
|
||||||
$lastname = (($firstname === $profile['channel_name']) ? '' : trim(substr($profile['channel_name'],strlen($firstname))));
|
$lastname = (($firstname === $profile['channel_name']) ? '' : trim(substr($profile['channel_name'],strlen($firstname))));
|
||||||
|
|
||||||
|
// @fixme move this to the diaspora plugin itself
|
||||||
|
|
||||||
|
if(plugin_is_installed('diaspora')) {
|
||||||
$diaspora = array(
|
$diaspora = array(
|
||||||
'podloc' => z_root(),
|
'podloc' => z_root(),
|
||||||
'guid' => $profile['channel_guid'] . str_replace('.','',App::get_hostname()),
|
'guid' => $profile['channel_guid'] . str_replace('.','',App::get_hostname()),
|
||||||
@ -1079,6 +1082,10 @@ function profile_sidebar($profile, $block = 0, $show_connect = true, $zcard = fa
|
|||||||
'photo100' => z_root() . '/photo/profile/100/' . $profile['uid'] . '.jpg',
|
'photo100' => z_root() . '/photo/profile/100/' . $profile['uid'] . '.jpg',
|
||||||
'photo50' => z_root() . '/photo/profile/50/' . $profile['uid'] . '.jpg',
|
'photo50' => z_root() . '/photo/profile/50/' . $profile['uid'] . '.jpg',
|
||||||
);
|
);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
$diaspora = '';
|
||||||
|
|
||||||
|
|
||||||
$contact_block = contact_block();
|
$contact_block = contact_block();
|
||||||
|
|
||||||
@ -1124,7 +1131,7 @@ function profile_sidebar($profile, $block = 0, $show_connect = true, $zcard = fa
|
|||||||
'$editmenu' => profile_edit_menu($profile['uid'])
|
'$editmenu' => profile_edit_menu($profile['uid'])
|
||||||
));
|
));
|
||||||
|
|
||||||
$arr = array('profile' => &$profile, 'entry' => &$o);
|
$arr = array('profile' => $profile, 'entry' => $o);
|
||||||
|
|
||||||
call_hooks('profile_sidebar', $arr);
|
call_hooks('profile_sidebar', $arr);
|
||||||
|
|
||||||
|
@ -52,6 +52,7 @@
|
|||||||
{{if $diaspora}}
|
{{if $diaspora}}
|
||||||
{{include file="diaspora_vcard.tpl"}}
|
{{include file="diaspora_vcard.tpl"}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div id="clear"></div>
|
<div id="clear"></div>
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user