Update translator documentation, i18n and L10n.
This commit is contained in:
parent
3501ad6c77
commit
e48c26e156
@ -41,7 +41,6 @@ require_once INSTALLDIR . '/lib/form.php';
|
|||||||
* @author Zach Copley <zach@status.net>
|
* @author Zach Copley <zach@status.net>
|
||||||
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
|
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
|
||||||
* @link http://status.net/
|
* @link http://status.net/
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
class InviteForm extends Form
|
class InviteForm extends Form
|
||||||
{
|
{
|
||||||
@ -95,21 +94,21 @@ class InviteForm extends Form
|
|||||||
{
|
{
|
||||||
$this->out->elementStart('ul', 'form_data');
|
$this->out->elementStart('ul', 'form_data');
|
||||||
$this->out->elementStart('li');
|
$this->out->elementStart('li');
|
||||||
// TRANS: Field label for a list of e-mail addresses.
|
|
||||||
$this->out->textarea(
|
$this->out->textarea(
|
||||||
'addresses',
|
'addresses',
|
||||||
|
// TRANS: Field label for a list of e-mail addresses.
|
||||||
_('Email addresses'),
|
_('Email addresses'),
|
||||||
$this->out->trimmed('addresses'),
|
$this->out->trimmed('addresses'),
|
||||||
// TRANS: Tooltip for field label for a list of e-mail addresses.
|
// TRANS: Field title for a list of e-mail addresses.
|
||||||
_('Addresses of friends to invite (one per line).')
|
_('Addresses of friends to invite (one per line).')
|
||||||
);
|
);
|
||||||
$this->out->elementEnd('li');
|
$this->out->elementEnd('li');
|
||||||
$this->out->elementStart('li');
|
$this->out->elementStart('li');
|
||||||
// TRANS: Field label for a personal message to send to invitees.
|
|
||||||
$this->out->textarea(
|
$this->out->textarea(
|
||||||
|
// TRANS: Field label for a personal message to send to invitees.
|
||||||
'personal', _('Personal message'),
|
'personal', _('Personal message'),
|
||||||
$this->out->trimmed('personal'),
|
$this->out->trimmed('personal'),
|
||||||
// TRANS: Tooltip for field label for a personal message to send to invitees.
|
// TRANS: Field title for a personal message to send to invitees.
|
||||||
_('Optionally add a personal message to the invitation.')
|
_('Optionally add a personal message to the invitation.')
|
||||||
);
|
);
|
||||||
$this->out->elementEnd('li');
|
$this->out->elementEnd('li');
|
||||||
@ -123,13 +122,13 @@ class InviteForm extends Form
|
|||||||
*/
|
*/
|
||||||
function formActions()
|
function formActions()
|
||||||
{
|
{
|
||||||
// TRANS: Send button for inviting friends
|
|
||||||
$this->out->submit(
|
$this->out->submit(
|
||||||
'send',
|
'send',
|
||||||
|
// TRANS: Send button for inviting friends
|
||||||
_m('BUTTON','Send'), 'submit form_action-primary',
|
_m('BUTTON','Send'), 'submit form_action-primary',
|
||||||
// TRANS: Submit button title.
|
|
||||||
'send',
|
'send',
|
||||||
_('Send')
|
// TRANS: Submit button title.
|
||||||
|
_('Send invitations.')
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -118,7 +118,7 @@ class DomainWhitelistPlugin extends Plugin
|
|||||||
} else {
|
} else {
|
||||||
// TRANS: Client exception thrown when a given e-mailaddress is not in the domain whitelist.
|
// TRANS: Client exception thrown when a given e-mailaddress is not in the domain whitelist.
|
||||||
// TRANS: %s are whitelisted e-mail domains separated by comma's (localisable).
|
// TRANS: %s are whitelisted e-mail domains separated by comma's (localisable).
|
||||||
$message = sprintf(_('Email address must be in one of these domains: %s.'),
|
$message = sprintf(_m('Email address must be in one of these domains: %s.'),
|
||||||
// TRANS: Separator for whitelisted domains.
|
// TRANS: Separator for whitelisted domains.
|
||||||
implode(_m('SEPARATOR',', '), $whitelist));
|
implode(_m('SEPARATOR',', '), $whitelist));
|
||||||
}
|
}
|
||||||
@ -132,7 +132,7 @@ class DomainWhitelistPlugin extends Plugin
|
|||||||
{
|
{
|
||||||
if (!$this->matchesWhitelist($email)) {
|
if (!$this->matchesWhitelist($email)) {
|
||||||
// TRANS: Exception thrown when an e-mail address does not match the site's domain whitelist.
|
// TRANS: Exception thrown when an e-mail address does not match the site's domain whitelist.
|
||||||
throw new Exception(_('That email address is not allowed on this site.'));
|
throw new Exception(_m('That email address is not allowed on this site.'));
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
@ -46,7 +46,7 @@ require_once INSTALLDIR . '/lib/form.php';
|
|||||||
class WhitelistInviteForm extends Form
|
class WhitelistInviteForm extends Form
|
||||||
{
|
{
|
||||||
private $whitelist = null;
|
private $whitelist = null;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Constructor
|
* Constructor
|
||||||
*
|
*
|
||||||
@ -86,7 +86,7 @@ class WhitelistInviteForm extends Form
|
|||||||
function formLegend()
|
function formLegend()
|
||||||
{
|
{
|
||||||
// TRANS: Form legend.
|
// TRANS: Form legend.
|
||||||
$this->out->element('legend', null, _('Invite collegues'));
|
$this->out->element('legend', null, _m('Invite collegues'));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -101,17 +101,17 @@ class WhitelistInviteForm extends Form
|
|||||||
$this->showEmailLI();
|
$this->showEmailLI();
|
||||||
}
|
}
|
||||||
$this->out->elementStart('li');
|
$this->out->elementStart('li');
|
||||||
// TRANS: Field label for a personal message to send to invitees.
|
|
||||||
$this->out->textarea(
|
$this->out->textarea(
|
||||||
'personal', _('Personal message'),
|
// TRANS: Field label for a personal message to send to invitees.
|
||||||
|
'personal', _m('Personal message'),
|
||||||
$this->out->trimmed('personal'),
|
$this->out->trimmed('personal'),
|
||||||
// TRANS: Tooltip for field label for a personal message to send to invitees.
|
// TRANS: Field title for a personal message to send to invitees.
|
||||||
_('Optionally add a personal message to the invitation.')
|
_m('Optionally add a personal message to the invitation.')
|
||||||
);
|
);
|
||||||
$this->out->elementEnd('li');
|
$this->out->elementEnd('li');
|
||||||
$this->out->elementEnd('ul');
|
$this->out->elementEnd('ul');
|
||||||
}
|
}
|
||||||
|
|
||||||
function showEmailLI()
|
function showEmailLI()
|
||||||
{
|
{
|
||||||
$this->out->elementStart('li');
|
$this->out->elementStart('li');
|
||||||
@ -119,8 +119,8 @@ class WhitelistInviteForm extends Form
|
|||||||
$this->out->text('@');
|
$this->out->text('@');
|
||||||
if (count($this->whitelist) == 1) {
|
if (count($this->whitelist) == 1) {
|
||||||
$this->out->element(
|
$this->out->element(
|
||||||
'span',
|
'span',
|
||||||
array('class' => 'email_invite'),
|
array('class' => 'email_invite'),
|
||||||
$this->whitelist[0]
|
$this->whitelist[0]
|
||||||
);
|
);
|
||||||
$this->out->hidden('domain[]', $this->whitelist[0]);
|
$this->out->hidden('domain[]', $this->whitelist[0]);
|
||||||
@ -154,10 +154,11 @@ class WhitelistInviteForm extends Form
|
|||||||
'href' => 'javascript://',
|
'href' => 'javascript://',
|
||||||
'style' => 'display: none;'
|
'style' => 'display: none;'
|
||||||
),
|
),
|
||||||
|
// TRANS: Link description to action to add another item to a list.
|
||||||
_m('Add another item')
|
_m('Add another item')
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Action elements
|
* Action elements
|
||||||
*
|
*
|
||||||
@ -165,13 +166,13 @@ class WhitelistInviteForm extends Form
|
|||||||
*/
|
*/
|
||||||
function formActions()
|
function formActions()
|
||||||
{
|
{
|
||||||
// TRANS: Send button for inviting friends
|
|
||||||
$this->out->submit(
|
$this->out->submit(
|
||||||
'send',
|
'send',
|
||||||
|
// TRANS: Send button for inviting friends.
|
||||||
_m('BUTTON','Send'), 'submit form_action-primary',
|
_m('BUTTON','Send'), 'submit form_action-primary',
|
||||||
// TRANS: Submit button title.
|
|
||||||
'send',
|
'send',
|
||||||
_('Send')
|
// TRANS: Submit button title.
|
||||||
|
_m('Send invitations.')
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user