Merge branch 'master' into 0.7.x
This commit is contained in:
commit
7b02d9d2e1
|
@ -73,11 +73,17 @@ class ShowgroupAction extends Action
|
||||||
|
|
||||||
function title()
|
function title()
|
||||||
{
|
{
|
||||||
|
if (!empty($this->group->fullname)) {
|
||||||
|
$base = $this->group->fullname . ' (' . $this->group->nickname . ')';
|
||||||
|
} else {
|
||||||
|
$base = $this->group->nickname;
|
||||||
|
}
|
||||||
|
|
||||||
if ($this->page == 1) {
|
if ($this->page == 1) {
|
||||||
return sprintf(_("%s group"), $this->group->nickname);
|
return sprintf(_("%s group"), $base);
|
||||||
} else {
|
} else {
|
||||||
return sprintf(_("%s group, page %d"),
|
return sprintf(_("%s group, page %d"),
|
||||||
$this->group->nickname,
|
$base,
|
||||||
$this->page);
|
$this->page);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -258,8 +258,12 @@ class NoticeListItem extends Widget
|
||||||
function showAuthor()
|
function showAuthor()
|
||||||
{
|
{
|
||||||
$this->out->elementStart('span', 'vcard author');
|
$this->out->elementStart('span', 'vcard author');
|
||||||
$this->out->elementStart('a', array('href' => $this->profile->profileurl,
|
$attrs = array('href' => $this->profile->profileurl,
|
||||||
'class' => 'url'));
|
'class' => 'url');
|
||||||
|
if (!empty($this->profile->fullname)) {
|
||||||
|
$attrs['title'] = $this->profile->fullname . ' (' . $this->profile->nickname . ') ';
|
||||||
|
}
|
||||||
|
$this->out->elementStart('a', $attrs);
|
||||||
$this->showAvatar();
|
$this->showAvatar();
|
||||||
$this->showNickname();
|
$this->showNickname();
|
||||||
$this->out->elementEnd('a');
|
$this->out->elementEnd('a');
|
||||||
|
|
16
lib/util.php
16
lib/util.php
|
@ -622,9 +622,13 @@ function common_at_link($sender_id, $nickname)
|
||||||
$url = $recipient->profileurl;
|
$url = $recipient->profileurl;
|
||||||
}
|
}
|
||||||
$xs = new XMLStringer(false);
|
$xs = new XMLStringer(false);
|
||||||
|
$attrs = array('href' => $url,
|
||||||
|
'class' => 'url');
|
||||||
|
if (!empty($recipient->fullname)) {
|
||||||
|
$attrs['title'] = $recipient->fullname . ' (' . $recipient->nickname . ')';
|
||||||
|
}
|
||||||
$xs->elementStart('span', 'vcard');
|
$xs->elementStart('span', 'vcard');
|
||||||
$xs->elementStart('a', array('href' => $url,
|
$xs->elementStart('a', $attrs);
|
||||||
'class' => 'url'));
|
|
||||||
$xs->element('span', 'fn nickname', $nickname);
|
$xs->element('span', 'fn nickname', $nickname);
|
||||||
$xs->elementEnd('a');
|
$xs->elementEnd('a');
|
||||||
$xs->elementEnd('span');
|
$xs->elementEnd('span');
|
||||||
|
@ -639,10 +643,14 @@ function common_group_link($sender_id, $nickname)
|
||||||
$sender = Profile::staticGet($sender_id);
|
$sender = Profile::staticGet($sender_id);
|
||||||
$group = User_group::staticGet('nickname', common_canonical_nickname($nickname));
|
$group = User_group::staticGet('nickname', common_canonical_nickname($nickname));
|
||||||
if ($group && $sender->isMember($group)) {
|
if ($group && $sender->isMember($group)) {
|
||||||
|
$attrs = array('href' => $group->permalink(),
|
||||||
|
'class' => 'url');
|
||||||
|
if (!empty($group->fullname)) {
|
||||||
|
$attrs['title'] = $group->fullname . ' (' . $group->nickname . ')';
|
||||||
|
}
|
||||||
$xs = new XMLStringer();
|
$xs = new XMLStringer();
|
||||||
$xs->elementStart('span', 'vcard');
|
$xs->elementStart('span', 'vcard');
|
||||||
$xs->elementStart('a', array('href' => $group->permalink(),
|
$xs->elementStart('a', $attrs);
|
||||||
'class' => 'url'));
|
|
||||||
$xs->element('span', 'fn nickname', $nickname);
|
$xs->element('span', 'fn nickname', $nickname);
|
||||||
$xs->elementEnd('a');
|
$xs->elementEnd('a');
|
||||||
$xs->elementEnd('span');
|
$xs->elementEnd('span');
|
||||||
|
|
Loading…
Reference in New Issue
Block a user