*
* @see GroupEditForm
*/
-
class SearchProfileForm extends Form
{
var $peopletag;
*
* @return string ID of the form
*/
-
function id()
{
return 'form_peopletag-add-' . $this->peopletag->id;
*
* @return string of the form class
*/
-
function formClass()
{
return 'form_peopletag_edit_user_search';
*
* @return string URL of the action
*/
-
function action()
{
return common_local_url('profilecompletion');
*
* @return void
*/
-
function formLegend()
{
+ // TRANS: Form legend.
$this->out->element('legend', null, sprintf(_('Search and list people')));
}
*
* @return void
*/
-
function formData()
{
- $fields = array('fulltext' => 'Everything',
- 'nickname' => 'Nickname',
- 'fullname' => 'Fullname',
- 'description' => 'Description',
- 'location' => 'Location',
- 'uri' => 'Uri (Remote users)');
-
+ // TRANS: Dropdown option for searching in profiles.
+ $fields = array('fulltext' => _('Everything'),
+ // TRANS: Dropdown option for searching in profiles.
+ 'nickname' => _('Nickname'),
+ // TRANS: Dropdown option for searching in profiles.
+ 'fullname' => _('Fullname'),
+ // TRANS: Dropdown option for searching in profiles.
+ 'description' => _('Description'),
+ // TRANS: Dropdown option for searching in profiles.
+ 'location' => _('Location'),
+ // TRANS: Dropdown option for searching in profiles.
+ 'uri' => _('URI (Remote users)'));
+
$this->out->hidden('peopletag_id', $this->peopletag->id);
$this->out->input('q', null);
- $this->out->dropdown('field', _('Search in'), $fields,
- _('Choose a field to search'), false, 'fulltext');
+ // TRANS: Dropdown field label.
+ $this->out->dropdown('field', _m('LABEL','Search in'), $fields,
+ // TRANS: Dropdown field title.
+ _('Choose a field to search.'), false, 'fulltext');
}
/**
*
* @return void
*/
-
function formActions()
{
- $this->out->submit('submit', _('Search'));
+ // TRANS: Button text to search profiles.
+ $this->out->submit('submit', _m('BUTTON','Search'));
}
}
*
* @return string ID of the form
*/
-
function id()
{
return 'form_peopletag-' . $this->peopletag->id . '-remove-' . $this->profile->id;
*
* @return string of the form class
*/
-
function formClass()
{
return 'form_user_remove_peopletag';
*
* @return void
*/
-
function formLegend()
{
- $this->out->element('legend', null, sprintf(_('Untag %s as %s'),
+ // TRANS: Form legend.
+ // TRANS: %1$s is a nickname, $2$s is a list.
+ $this->out->element('legend', null, sprintf(_('Remove %1$s from list %2$s'),
$this->profile->nickname, $this->peopletag->tag));
}
*
* @return void
*/
-
function formData()
{
$this->out->hidden('peopletag_id', $this->peopletag->id);
*
* @return void
*/
-
function formActions()
{
- $this->out->submit('submit', _('Remove'));
+ // TRANS: Button text to untag a profile.
+ $this->out->submit('submit', _m('BUTTON','Remove'));
}
}
-
class TagButton extends Form
{
var $profile;
*
* @return string ID of the form
*/
-
function id()
{
return 'form_peopletag-' . $this->peopletag->id . '-add-' . $this->profile->id;
*
* @return string of the form class
*/
-
function formClass()
{
return 'form_user_add_peopletag';
*
* @return string URL of the action
*/
-
function action()
{
return common_local_url('addpeopletag');
*
* @return void
*/
-
function formLegend()
{
- $this->out->element('legend', null, sprintf(_('Tag %s as %s'),
+ // TRANS: Legend on form to add a profile to a list.
+ // TRANS: %1$s is a nickname, %2$s is a list.
+ $this->out->element('legend', null, sprintf(_('Add %1$s to list %2$s'),
$this->profile->nickname, $this->peopletag->tag));
}
*
* @return void
*/
-
function formData()
{
UntagButton::formData();
*
* @return void
*/
-
function formActions()
{
- $this->out->submit('submit', _('Add'));
+ // TRANS: Button text to tag a profile.
+ $this->out->submit('submit', _m('BUTTON','Add'));
}
}
$this->out->elementStart('a', array('class' => 'url',
'href' => $this->profile->profileurl,
'title' => $this->profile->getBestName()));
- $avatar = $this->profile->getAvatar(AVATAR_MINI_SIZE);
- $this->out->element('img', array('src' => (($avatar) ? $avatar->displayUrl() :
- Avatar::defaultImage(AVATAR_MINI_SIZE)),
+ $avatarUrl = $this->profile->avatarUrl(AVATAR_MINI_SIZE);
+ $this->out->element('img', array('src' => $avatarUrl,
'width' => AVATAR_MINI_SIZE,
'height' => AVATAR_MINI_SIZE,
'class' => 'avatar photo',