move friend suggestions to top of contact page, add default contact profile photos if missing
This commit is contained in:
parent
def0e35e21
commit
ef33cfcc9a
2 changed files with 23 additions and 2 deletions
|
@ -395,6 +395,11 @@ function contacts_content(&$a) {
|
||||||
$nets = ((x($_GET,'nets')) ? notags(trim($_GET['nets'])) : '');
|
$nets = ((x($_GET,'nets')) ? notags(trim($_GET['nets'])) : '');
|
||||||
|
|
||||||
$tabs = array(
|
$tabs = array(
|
||||||
|
array(
|
||||||
|
'label' => t('Suggestions'),
|
||||||
|
'url' => $a->get_baseurl(true) . '/suggest',
|
||||||
|
'sel' => '',
|
||||||
|
),
|
||||||
array(
|
array(
|
||||||
'label' => t('All Contacts'),
|
'label' => t('All Contacts'),
|
||||||
'url' => $a->get_baseurl(true) . '/contacts/all',
|
'url' => $a->get_baseurl(true) . '/contacts/all',
|
||||||
|
|
|
@ -115,8 +115,24 @@ function photo_init(&$a) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if(! isset($data)) {
|
if(! isset($data)) {
|
||||||
|
if(isset($resolution)) {
|
||||||
|
switch($resolution) {
|
||||||
|
|
||||||
|
case 4:
|
||||||
|
$data = file_get_contents('images/person-175.jpg');
|
||||||
|
break;
|
||||||
|
case 5:
|
||||||
|
$data = file_get_contents('images/person-80.jpg');
|
||||||
|
break;
|
||||||
|
case 6:
|
||||||
|
$data = file_get_contents('images/person-48.jpg');
|
||||||
|
break;
|
||||||
|
default:
|
||||||
killme();
|
killme();
|
||||||
// NOTREACHED
|
// NOTREACHED
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(isset($customres) && $customres > 0 && $customres < 500) {
|
if(isset($customres) && $customres > 0 && $customres < 500) {
|
||||||
|
|
Loading…
Reference in a new issue