1
0
Fork 0

Merge pull request #13339 from MrPetovan/task/13332-deprecate-profile-name

Deprecate profile.name in favor of user.username
This commit is contained in:
Michael Vogel 2023-08-20 20:18:47 +02:00 committed by GitHub
commit fe48fcf9de
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
14 changed files with 585 additions and 713 deletions

View file

@ -1,6 +1,6 @@
-- ------------------------------------------ -- ------------------------------------------
-- Friendica 2023.09-dev (Giant Rhubarb) -- Friendica 2023.09-dev (Giant Rhubarb)
-- DB_UPDATE_VERSION 1524 -- DB_UPDATE_VERSION 1525
-- ------------------------------------------ -- ------------------------------------------
@ -1586,7 +1586,7 @@ CREATE TABLE IF NOT EXISTS `profile` (
`profile-name` varchar(255) COMMENT 'Deprecated', `profile-name` varchar(255) COMMENT 'Deprecated',
`is-default` boolean COMMENT 'Deprecated', `is-default` boolean COMMENT 'Deprecated',
`hide-friends` boolean NOT NULL DEFAULT '0' COMMENT 'Hide friend list from viewers of this profile', `hide-friends` boolean NOT NULL DEFAULT '0' COMMENT 'Hide friend list from viewers of this profile',
`name` varchar(255) NOT NULL DEFAULT '' COMMENT '', `name` varchar(255) NOT NULL DEFAULT '' COMMENT 'Unused in favor of user.username',
`pdesc` varchar(255) COMMENT 'Deprecated', `pdesc` varchar(255) COMMENT 'Deprecated',
`dob` varchar(32) NOT NULL DEFAULT '0000-00-00' COMMENT 'Day of birth', `dob` varchar(32) NOT NULL DEFAULT '0000-00-00' COMMENT 'Day of birth',
`address` varchar(255) NOT NULL DEFAULT '' COMMENT '', `address` varchar(255) NOT NULL DEFAULT '' COMMENT '',

View file

@ -13,7 +13,7 @@ Fields
| profile-name | Deprecated | varchar(255) | YES | | NULL | | | profile-name | Deprecated | varchar(255) | YES | | NULL | |
| is-default | Deprecated | boolean | YES | | NULL | | | is-default | Deprecated | boolean | YES | | NULL | |
| hide-friends | Hide friend list from viewers of this profile | boolean | NO | | 0 | | | hide-friends | Hide friend list from viewers of this profile | boolean | NO | | 0 | |
| name | | varchar(255) | NO | | | | | name | Unused in favor of user.username | varchar(255) | NO | | | |
| pdesc | Deprecated | varchar(255) | YES | | NULL | | | pdesc | Deprecated | varchar(255) | YES | | NULL | |
| dob | Day of birth | varchar(32) | NO | | 0000-00-00 | | | dob | Day of birth | varchar(32) | NO | | 0000-00-00 | |
| address | | varchar(255) | NO | | | | | address | | varchar(255) | NO | | | |

View file

@ -788,10 +788,10 @@ class Contact
/** /**
* Updates the self-contact for the provided user id * Updates the self-contact for the provided user id
* *
* @param int $uid * @param int $uid
* @param bool $update_avatar Force the avatar update * @param bool $update_avatar Force the avatar update
* @return bool "true" if updated * @return bool "true" if updated
* @throws HTTPException\InternalServerErrorException * @throws \Exception
*/ */
public static function updateSelfFromUserID(int $uid, bool $update_avatar = false): bool public static function updateSelfFromUserID(int $uid, bool $update_avatar = false): bool
{ {

View file

@ -37,6 +37,7 @@ use Friendica\DI;
use Friendica\Network\HTTPClient\Client\HttpClientAccept; use Friendica\Network\HTTPClient\Client\HttpClientAccept;
use Friendica\Network\HTTPClient\Client\HttpClientOptions; use Friendica\Network\HTTPClient\Client\HttpClientOptions;
use Friendica\Network\HTTPException; use Friendica\Network\HTTPException;
use Friendica\Network\HTTPException\InternalServerErrorException;
use Friendica\Protocol\Activity; use Friendica\Protocol\Activity;
use Friendica\Protocol\Diaspora; use Friendica\Protocol\Diaspora;
use Friendica\Security\PermissionSet\Entity\PermissionSet; use Friendica\Security\PermissionSet\Entity\PermissionSet;
@ -93,10 +94,11 @@ class Profile
/** /**
* Update a profile entry and distribute the changes if needed * Update a profile entry and distribute the changes if needed
* *
* @param array $fields Profile fields to update * @param array $fields Profile fields to update
* @param integer $uid User id * @param integer $uid User id
* *
* @return boolean Whether update was successful * @return boolean Whether update was successful
* @throws \Exception
*/ */
public static function update(array $fields, int $uid): bool public static function update(array $fields, int $uid): bool
{ {
@ -116,10 +118,6 @@ class Profile
return false; return false;
} }
if ($old_owner['name'] != $owner['name']) {
User::update(['username' => $owner['name']], $uid);
}
$profile_fields = ['postal-code', 'dob', 'prv_keywords', 'homepage']; $profile_fields = ['postal-code', 'dob', 'prv_keywords', 'homepage'];
foreach ($profile_fields as $field) { foreach ($profile_fields as $field) {
if ($old_owner[$field] != $owner[$field]) { if ($old_owner[$field] != $owner[$field]) {

View file

@ -37,6 +37,7 @@ use Friendica\Database\DBA;
use Friendica\DI; use Friendica\DI;
use Friendica\Module; use Friendica\Module;
use Friendica\Network\HTTPClient\Client\HttpClientAccept; use Friendica\Network\HTTPClient\Client\HttpClientAccept;
use Friendica\Network\HTTPException\InternalServerErrorException;
use Friendica\Security\TwoFactor\Model\AppSpecificPassword; use Friendica\Security\TwoFactor\Model\AppSpecificPassword;
use Friendica\Network\HTTPException; use Friendica\Network\HTTPException;
use Friendica\Object\Image; use Friendica\Object\Image;
@ -1328,33 +1329,18 @@ class User
/** /**
* Update a user entry and distribute the changes if needed * Update a user entry and distribute the changes if needed
* *
* @param array $fields * @param array $fields
* @param integer $uid * @param integer $uid
* @return boolean * @return boolean
* @throws Exception
*/ */
public static function update(array $fields, int $uid): bool public static function update(array $fields, int $uid): bool
{ {
$old_owner = self::getOwnerDataById($uid);
if (empty($old_owner)) {
return false;
}
if (!DBA::update('user', $fields, ['uid' => $uid])) { if (!DBA::update('user', $fields, ['uid' => $uid])) {
return false; return false;
} }
$update = Contact::updateSelfFromUserID($uid); if (Contact::updateSelfFromUserID($uid)) {
$owner = self::getOwnerDataById($uid);
if (empty($owner)) {
return false;
}
if ($old_owner['name'] != $owner['name']) {
Profile::update(['name' => $owner['name']], $uid);
}
if ($update) {
Profile::publishUpdate($uid); Profile::publishUpdate($uid);
} }

View file

@ -573,7 +573,7 @@ class Account extends BaseSettings
'$delete_openid' => ['delete_openid', DI::l10n()->t('Delete OpenID URL'), false, ''], '$delete_openid' => ['delete_openid', DI::l10n()->t('Delete OpenID URL'), false, ''],
'$h_basic' => DI::l10n()->t('Basic Settings'), '$h_basic' => DI::l10n()->t('Basic Settings'),
'$username' => ['username', DI::l10n()->t('Full Name:'), $username, '', false, 'autocomplete="off"'], '$username' => ['username', DI::l10n()->t('Display name:'), $username, '', false, 'autocomplete="off"'],
'$email' => ['email', DI::l10n()->t('Email Address:'), $email, '', '', 'autocomplete="off"', 'email'], '$email' => ['email', DI::l10n()->t('Email Address:'), $email, '', '', 'autocomplete="off"', 'email'],
'$timezone' => ['timezone_select', DI::l10n()->t('Your Timezone:'), Temporal::getTimezoneSelect($timezone), ''], '$timezone' => ['timezone_select', DI::l10n()->t('Your Timezone:'), Temporal::getTimezoneSelect($timezone), ''],
'$language' => ['language', DI::l10n()->t('Your Language:'), $language, DI::l10n()->t('Set the language we use to show you friendica interface and to send you emails'), $lang_choices], '$language' => ['language', DI::l10n()->t('Your Language:'), $language, DI::l10n()->t('Set the language we use to show you friendica interface and to send you emails'), $lang_choices],

View file

@ -21,43 +21,75 @@
namespace Friendica\Module\Settings\Profile; namespace Friendica\Module\Settings\Profile;
use Friendica\App;
use Friendica\Core\ACL; use Friendica\Core\ACL;
use Friendica\Core\Hook; use Friendica\Core\Hook;
use Friendica\Core\L10n;
use Friendica\Core\Protocol; use Friendica\Core\Protocol;
use Friendica\Core\Renderer; use Friendica\Core\Renderer;
use Friendica\Core\Session\Capability\IHandleUserSessions;
use Friendica\Core\Theme; use Friendica\Core\Theme;
use Friendica\Database\DBA; use Friendica\Database\DBA;
use Friendica\DI;
use Friendica\Model\Contact; use Friendica\Model\Contact;
use Friendica\Model\Profile; use Friendica\Model\Profile;
use Friendica\Profile\ProfileField\Collection\ProfileFields; use Friendica\Module\Response;
use Friendica\Profile\ProfileField\Entity\ProfileField; use Friendica\Navigation\SystemMessages;
use Friendica\Profile\ProfileField;
use Friendica\Model\User; use Friendica\Model\User;
use Friendica\Module\BaseSettings; use Friendica\Module\BaseSettings;
use Friendica\Module\Security\Login; use Friendica\Module\Security\Login;
use Friendica\Network\HTTPException; use Friendica\Network\HTTPException;
use Friendica\Security\PermissionSet;
use Friendica\Util\ACLFormatter;
use Friendica\Util\DateTimeFormat; use Friendica\Util\DateTimeFormat;
use Friendica\Util\Profiler;
use Friendica\Util\Temporal; use Friendica\Util\Temporal;
use Friendica\Core\Worker; use Friendica\Core\Worker;
use Psr\Log\LoggerInterface;
class Index extends BaseSettings class Index extends BaseSettings
{ {
/** @var ProfileField\Repository\ProfileField */
private $profileFieldRepo;
/** @var ProfileField\Factory\ProfileField */
private $profileFieldFactory;
/** @var SystemMessages */
private $systemMessages;
/** @var PermissionSet\Repository\PermissionSet */
private $permissionSetRepo;
/** @var PermissionSet\Factory\PermissionSet */
private $permissionSetFactory;
/** @var ACLFormatter */
private $aclFormatter;
public function __construct(ACLFormatter $aclFormatter, PermissionSet\Factory\PermissionSet $permissionSetFactory, PermissionSet\Repository\PermissionSet $permissionSetRepo, SystemMessages $systemMessages, ProfileField\Factory\ProfileField $profileFieldFactory, ProfileField\Repository\ProfileField $profileFieldRepo, IHandleUserSessions $session, App\Page $page, L10n $l10n, App\BaseURL $baseUrl, App\Arguments $args, LoggerInterface $logger, Profiler $profiler, Response $response, array $server, array $parameters = [])
{
parent::__construct($session, $page, $l10n, $baseUrl, $args, $logger, $profiler, $response, $server, $parameters);
$this->profileFieldRepo = $profileFieldRepo;
$this->profileFieldFactory = $profileFieldFactory;
$this->systemMessages = $systemMessages;
$this->permissionSetRepo = $permissionSetRepo;
$this->permissionSetFactory = $permissionSetFactory;
$this->aclFormatter = $aclFormatter;
}
protected function post(array $request = []) protected function post(array $request = [])
{ {
if (!DI::userSession()->getLocalUserId()) { if (!$this->session->getLocalUserId()) {
return; return;
} }
$profile = Profile::getByUID(DI::userSession()->getLocalUserId()); $profile = Profile::getByUID($this->session->getLocalUserId());
if (!DBA::isResult($profile)) { if (!$profile) {
return; return;
} }
self::checkFormSecurityTokenRedirectOnError('/settings/profile', 'settings_profile'); self::checkFormSecurityTokenRedirectOnError('/settings/profile', 'settings_profile');
Hook::callAll('profile_post', $_POST); Hook::callAll('profile_post', $request);
$dob = trim($_POST['dob'] ?? ''); $dob = trim($request['dob'] ?? '');
if ($dob && !in_array($dob, ['0000-00-00', DBA::NULL_DATE])) { if ($dob && !in_array($dob, ['0000-00-00', DBA::NULL_DATE])) {
$y = substr($dob, 0, 4); $y = substr($dob, 0, 4);
@ -79,39 +111,40 @@ class Index extends BaseSettings
} }
} }
$name = trim($_POST['name'] ?? ''); $username = trim($request['username'] ?? '');
if (!strlen($name)) { if (!$username) {
DI::sysmsg()->addNotice(DI::l10n()->t('Profile Name is required.')); $this->systemMessages->addNotice($this->t('Display Name is required.'));
return; return;
} }
$about = trim($_POST['about']); $about = trim($request['about']);
$address = trim($_POST['address']); $address = trim($request['address']);
$locality = trim($_POST['locality']); $locality = trim($request['locality']);
$region = trim($_POST['region']); $region = trim($request['region']);
$postal_code = trim($_POST['postal_code']); $postal_code = trim($request['postal_code']);
$country_name = trim($_POST['country_name']); $country_name = trim($request['country_name']);
$pub_keywords = self::cleanKeywords(trim($_POST['pub_keywords'])); $pub_keywords = self::cleanKeywords(trim($request['pub_keywords']));
$prv_keywords = self::cleanKeywords(trim($_POST['prv_keywords'])); $prv_keywords = self::cleanKeywords(trim($request['prv_keywords']));
$xmpp = trim($_POST['xmpp']); $xmpp = trim($request['xmpp']);
$matrix = trim($_POST['matrix']); $matrix = trim($request['matrix']);
$homepage = trim($_POST['homepage']); $homepage = trim($request['homepage']);
if ((strpos($homepage, 'http') !== 0) && (strlen($homepage))) { if ((strpos($homepage, 'http') !== 0) && (strlen($homepage))) {
// neither http nor https in URL, add them // neither http nor https in URL, add them
$homepage = 'http://' . $homepage; $homepage = 'http://' . $homepage;
} }
$profileFieldsNew = self::getProfileFieldsFromInput( $profileFieldsNew = $this->getProfileFieldsFromInput(
DI::userSession()->getLocalUserId(), $this->session->getLocalUserId(),
$_REQUEST['profile_field'], $request['profile_field'],
$_REQUEST['profile_field_order'] $request['profile_field_order']
); );
DI::profileField()->saveCollectionForUser(DI::userSession()->getLocalUserId(), $profileFieldsNew); $this->profileFieldRepo->saveCollectionForUser($this->session->getLocalUserId(), $profileFieldsNew);
User::update(['username' => $username], $this->session->getLocalUserId());
$result = Profile::update( $result = Profile::update(
[ [
'name' => $name,
'about' => $about, 'about' => $about,
'dob' => $dob, 'dob' => $dob,
'address' => $address, 'address' => $address,
@ -125,23 +158,23 @@ class Index extends BaseSettings
'pub_keywords' => $pub_keywords, 'pub_keywords' => $pub_keywords,
'prv_keywords' => $prv_keywords, 'prv_keywords' => $prv_keywords,
], ],
DI::userSession()->getLocalUserId() $this->session->getLocalUserId()
); );
Worker::add(Worker::PRIORITY_MEDIUM, 'CheckRelMeProfileLink', DI::userSession()->getLocalUserId()); Worker::add(Worker::PRIORITY_MEDIUM, 'CheckRelMeProfileLink', $this->session->getLocalUserId());
if (!$result) { if (!$result) {
DI::sysmsg()->addNotice(DI::l10n()->t('Profile couldn\'t be updated.')); $this->systemMessages->addNotice($this->t("Profile couldn't be updated."));
return; return;
} }
DI::baseUrl()->redirect('settings/profile'); $this->baseUrl->redirect('settings/profile');
} }
protected function content(array $request = []): string protected function content(array $request = []): string
{ {
if (!DI::userSession()->getLocalUserId()) { if (!$this->session->getLocalUserId()) {
DI::sysmsg()->addNotice(DI::l10n()->t('You must be logged in to use this module')); $this->systemMessages->addNotice($this->t('You must be logged in to use this module'));
return Login::form(); return Login::form();
} }
@ -149,147 +182,145 @@ class Index extends BaseSettings
$o = ''; $o = '';
$profile = User::getOwnerDataById(DI::userSession()->getLocalUserId()); $owner = User::getOwnerDataById($this->session->getLocalUserId());
if (!DBA::isResult($profile)) { if (!$owner) {
throw new HTTPException\NotFoundException(); throw new HTTPException\NotFoundException();
} }
$a = DI::app(); $this->page->registerFooterScript('view/asset/es-jquery-sortable/source/js/jquery-sortable-min.js');
$this->page->registerFooterScript(Theme::getPathForFile('js/module/settings/profile/index.js'));
DI::page()->registerFooterScript('view/asset/es-jquery-sortable/source/js/jquery-sortable-min.js');
DI::page()->registerFooterScript(Theme::getPathForFile('js/module/settings/profile/index.js'));
$custom_fields = []; $custom_fields = [];
$profileFields = DI::profileField()->selectByUserId(DI::userSession()->getLocalUserId()); $profileFields = $this->profileFieldRepo->selectByUserId($this->session->getLocalUserId());
foreach ($profileFields as $profileField) { foreach ($profileFields as $profileField) {
/** @var ProfileField $profileField */
$defaultPermissions = $profileField->permissionSet->withAllowedContacts( $defaultPermissions = $profileField->permissionSet->withAllowedContacts(
Contact::pruneUnavailable($profileField->permissionSet->allow_cid) Contact::pruneUnavailable($profileField->permissionSet->allow_cid)
); );
$custom_fields[] = [ $custom_fields[] = [
'id' => $profileField->id, 'id' => $profileField->id,
'legend' => $profileField->label, 'legend' => $profileField->label,
'fields' => [ 'fields' => [
'label' => ['profile_field[' . $profileField->id . '][label]', DI::l10n()->t('Label:'), $profileField->label], 'label' => ['profile_field[' . $profileField->id . '][label]', $this->t('Label:'), $profileField->label],
'value' => ['profile_field[' . $profileField->id . '][value]', DI::l10n()->t('Value:'), $profileField->value], 'value' => ['profile_field[' . $profileField->id . '][value]', $this->t('Value:'), $profileField->value],
'acl' => ACL::getFullSelectorHTML( 'acl' => ACL::getFullSelectorHTML(
DI::page(), $this->page,
$a->getLoggedInUserId(), $this->session->getLocalUserId(),
false, false,
$defaultPermissions->toArray(), $defaultPermissions->toArray(),
['network' => Protocol::DFRN], ['network' => Protocol::DFRN],
'profile_field[' . $profileField->id . ']' 'profile_field[' . $profileField->id . ']'
), ),
], ],
'permissions' => DI::l10n()->t('Field Permissions'),
'permdesc' => DI::l10n()->t("(click to open/close)"), 'permissions' => $this->t('Field Permissions'),
'permdesc' => $this->t("(click to open/close)"),
]; ];
}; }
$custom_fields[] = [ $custom_fields[] = [
'id' => 'new', 'id' => 'new',
'legend' => DI::l10n()->t('Add a new profile field'), 'legend' => $this->t('Add a new profile field'),
'fields' => [ 'fields' => [
'label' => ['profile_field[new][label]', DI::l10n()->t('Label:')], 'label' => ['profile_field[new][label]', $this->t('Label:')],
'value' => ['profile_field[new][value]', DI::l10n()->t('Value:')], 'value' => ['profile_field[new][value]', $this->t('Value:')],
'acl' => ACL::getFullSelectorHTML( 'acl' => ACL::getFullSelectorHTML(
DI::page(), $this->page,
$a->getLoggedInUserId(), $this->session->getLocalUserId(),
false, false,
['allow_cid' => []], ['allow_cid' => []],
['network' => Protocol::DFRN], ['network' => Protocol::DFRN],
'profile_field[new]' 'profile_field[new]'
), ),
], ],
'permissions' => DI::l10n()->t('Field Permissions'),
'permdesc' => DI::l10n()->t("(click to open/close)"), 'permissions' => $this->t('Field Permissions'),
'permdesc' => $this->t("(click to open/close)"),
]; ];
DI::page()['htmlhead'] .= Renderer::replaceMacros(Renderer::getMarkupTemplate('settings/profile/index_head.tpl'), [ $this->page['htmlhead'] .= Renderer::replaceMacros(Renderer::getMarkupTemplate('settings/profile/index_head.tpl'));
]);
$personal_account = ($profile['account-type'] != User::ACCOUNT_TYPE_COMMUNITY); $personal_account = ($owner['account-type'] != User::ACCOUNT_TYPE_COMMUNITY);
if ($profile['homepage_verified']) { if ($owner['homepage_verified']) {
$homepage_help_text = DI::l10n()->t('The homepage is verified. A rel="me" link back to your Friendica profile page was found on the homepage.'); $homepage_help_text = $this->t('The homepage is verified. A rel="me" link back to your Friendica profile page was found on the homepage.');
} else { } else {
$homepage_help_text = DI::l10n()->t('To verify your homepage, add a rel="me" link to it, pointing to your profile URL (%s).', $profile['url']); $homepage_help_text = $this->t('To verify your homepage, add a rel="me" link to it, pointing to your profile URL (%s).', $owner['url']);
} }
$tpl = Renderer::getMarkupTemplate('settings/profile/index.tpl'); $tpl = Renderer::getMarkupTemplate('settings/profile/index.tpl');
$o .= Renderer::replaceMacros($tpl, [ $o .= Renderer::replaceMacros($tpl, [
'$personal_account' => $personal_account, '$l10n' => [
'profile_action' => $this->t('Profile Actions'),
'$form_security_token' => self::getFormSecurityToken('settings_profile'), 'banner' => $this->t('Edit Profile Details'),
'$form_security_token_photo' => self::getFormSecurityToken('settings_profile_photo'), 'submit' => $this->t('Submit'),
'profpic' => $this->t('Change Profile Photo'),
'$profile_action' => DI::l10n()->t('Profile Actions'), 'viewprof' => $this->t('View Profile'),
'$banner' => DI::l10n()->t('Edit Profile Details'), 'personal_section' => $this->t('Personal'),
'$submit' => DI::l10n()->t('Submit'), 'picture_section' => $this->t('Profile picture'),
'$profpic' => DI::l10n()->t('Change Profile Photo'), 'location_section' => $this->t('Location'),
'$profpiclink' => '/profile/' . $profile['nickname'] . '/photos', 'miscellaneous_section' => $this->t('Miscellaneous'),
'$viewprof' => DI::l10n()->t('View Profile'), 'custom_fields_section' => $this->t('Custom Profile Fields'),
'profile_photo' => $this->t('Upload Profile Photo'),
'$lbl_personal_section' => DI::l10n()->t('Personal'), 'custom_fields_description' => $this->t('<p>Custom fields appear on <a href="%s">your profile page</a>.</p>
'$lbl_picture_section' => DI::l10n()->t('Profile picture'),
'$lbl_location_section' => DI::l10n()->t('Location'),
'$lbl_miscellaneous_section' => DI::l10n()->t('Miscellaneous'),
'$lbl_custom_fields_section' => DI::l10n()->t('Custom Profile Fields'),
'$lbl_profile_photo' => DI::l10n()->t('Upload Profile Photo'),
'$baseurl' => DI::baseUrl(),
'$nickname' => $profile['nickname'],
'$name' => ['name', DI::l10n()->t('Display name:'), $profile['name']],
'$about' => ['about', DI::l10n()->t('Description:'), $profile['about']],
'$dob' => Temporal::getDateofBirthField($profile['dob'], $profile['timezone']),
'$address' => ['address', DI::l10n()->t('Street Address:'), $profile['address']],
'$locality' => ['locality', DI::l10n()->t('Locality/City:'), $profile['locality']],
'$region' => ['region', DI::l10n()->t('Region/State:'), $profile['region']],
'$postal_code' => ['postal_code', DI::l10n()->t('Postal/Zip Code:'), $profile['postal-code']],
'$country_name' => ['country_name', DI::l10n()->t('Country:'), $profile['country-name']],
'$age' => ((intval($profile['dob'])) ? '(' . DI::l10n()->t('Age: ') . DI::l10n()->tt('%d year old', '%d years old', Temporal::getAgeByTimezone($profile['dob'], $profile['timezone'])) . ')' : ''),
'$xmpp' => ['xmpp', DI::l10n()->t('XMPP (Jabber) address:'), $profile['xmpp'], DI::l10n()->t('The XMPP address will be published so that people can follow you there.')],
'$matrix' => ['matrix', DI::l10n()->t('Matrix (Element) address:'), $profile['matrix'], DI::l10n()->t('The Matrix address will be published so that people can follow you there.')],
'$homepage' => ['homepage', DI::l10n()->t('Homepage URL:'), $profile['homepage'], $homepage_help_text],
'$pub_keywords' => ['pub_keywords', DI::l10n()->t('Public Keywords:'), $profile['pub_keywords'], DI::l10n()->t('(Used for suggesting potential friends, can be seen by others)')],
'$prv_keywords' => ['prv_keywords', DI::l10n()->t('Private Keywords:'), $profile['prv_keywords'], DI::l10n()->t('(Used for searching profiles, never shown to others)')],
'$custom_fields_description' => DI::l10n()->t("<p>Custom fields appear on <a href=\"%s\">your profile page</a>.</p>
<p>You can use BBCodes in the field values.</p> <p>You can use BBCodes in the field values.</p>
<p>Reorder by dragging the field title.</p> <p>Reorder by dragging the field title.</p>
<p>Empty the label field to remove a custom field.</p> <p>Empty the label field to remove a custom field.</p>
<p>Non-public fields can only be seen by the selected Friendica contacts or the Friendica contacts in the selected circles.</p>", <p>Non-public fields can only be seen by the selected Friendica contacts or the Friendica contacts in the selected circles.</p>',
'profile/' . $profile['nickname'] . '/profile' 'profile/' . $owner['nickname'] . '/profile'
), ),
],
'$personal_account' => $personal_account,
'$form_security_token' => self::getFormSecurityToken('settings_profile'),
'$form_security_token_photo' => self::getFormSecurityToken('settings_profile_photo'),
'$profpiclink' => '/profile/' . $owner['nickname'] . '/photos',
'$nickname' => $owner['nickname'],
'$username' => ['username', $this->t('Display name:'), $owner['name']],
'$about' => ['about', $this->t('Description:'), $owner['about']],
'$dob' => Temporal::getDateofBirthField($owner['dob'], $owner['timezone']),
'$address' => ['address', $this->t('Street Address:'), $owner['address']],
'$locality' => ['locality', $this->t('Locality/City:'), $owner['locality']],
'$region' => ['region', $this->t('Region/State:'), $owner['region']],
'$postal_code' => ['postal_code', $this->t('Postal/Zip Code:'), $owner['postal-code']],
'$country_name' => ['country_name', $this->t('Country:'), $owner['country-name']],
'$age' => ((intval($owner['dob'])) ? '(' . $this->t('Age: ') . $this->tt('%d year old', '%d years old', Temporal::getAgeByTimezone($owner['dob'], $owner['timezone'])) . ')' : ''),
'$xmpp' => ['xmpp', $this->t('XMPP (Jabber) address:'), $owner['xmpp'], $this->t('The XMPP address will be published so that people can follow you there.')],
'$matrix' => ['matrix', $this->t('Matrix (Element) address:'), $owner['matrix'], $this->t('The Matrix address will be published so that people can follow you there.')],
'$homepage' => ['homepage', $this->t('Homepage URL:'), $owner['homepage'], $homepage_help_text],
'$pub_keywords' => ['pub_keywords', $this->t('Public Keywords:'), $owner['pub_keywords'], $this->t('(Used for suggesting potential friends, can be seen by others)')],
'$prv_keywords' => ['prv_keywords', $this->t('Private Keywords:'), $owner['prv_keywords'], $this->t('(Used for searching profiles, never shown to others)')],
'$custom_fields' => $custom_fields, '$custom_fields' => $custom_fields,
]); ]);
$arr = ['profile' => $profile, 'entry' => $o]; $arr = ['profile' => $owner, 'entry' => $o];
Hook::callAll('profile_edit', $arr); Hook::callAll('profile_edit', $arr);
return $o; return $o;
} }
private static function getProfileFieldsFromInput(int $uid, array $profileFieldInputs, array $profileFieldOrder): ProfileFields private function getProfileFieldsFromInput(int $uid, array $profileFieldInputs, array $profileFieldOrder): ProfileField\Collection\ProfileFields
{ {
$profileFields = new ProfileFields(); $profileFields = new ProfileField\Collection\ProfileFields();
// Returns an associative array of id => order values // Returns an associative array of id => order values
$profileFieldOrder = array_flip($profileFieldOrder); $profileFieldOrder = array_flip($profileFieldOrder);
// Creation of the new field // Creation of the new field
if (!empty($profileFieldInputs['new']['label'])) { if (!empty($profileFieldInputs['new']['label'])) {
$permissionSet = DI::permissionSet()->selectOrCreate(DI::permissionSetFactory()->createFromString( $permissionSet = $this->permissionSetRepo->selectOrCreate($this->permissionSetFactory->createFromString(
$uid, $uid,
DI::aclFormatter()->toString($profileFieldInputs['new']['contact_allow'] ?? ''), $this->aclFormatter->toString($profileFieldInputs['new']['contact_allow'] ?? ''),
DI::aclFormatter()->toString($profileFieldInputs['new']['circle_allow'] ?? ''), $this->aclFormatter->toString($profileFieldInputs['new']['circle_allow'] ?? ''),
DI::aclFormatter()->toString($profileFieldInputs['new']['contact_deny'] ?? ''), $this->aclFormatter->toString($profileFieldInputs['new']['contact_deny'] ?? ''),
DI::aclFormatter()->toString($profileFieldInputs['new']['circle_deny'] ?? '') $this->aclFormatter->toString($profileFieldInputs['new']['circle_deny'] ?? '')
)); ));
$profileFields->append(DI::profileFieldFactory()->createFromValues( $profileFields->append($this->profileFieldFactory->createFromValues(
$uid, $uid,
$profileFieldOrder['new'], $profileFieldOrder['new'],
$profileFieldInputs['new']['label'], $profileFieldInputs['new']['label'],
@ -302,15 +333,15 @@ class Index extends BaseSettings
unset($profileFieldOrder['new']); unset($profileFieldOrder['new']);
foreach ($profileFieldInputs as $id => $profileFieldInput) { foreach ($profileFieldInputs as $id => $profileFieldInput) {
$permissionSet = DI::permissionSet()->selectOrCreate(DI::permissionSetFactory()->createFromString( $permissionSet = $this->permissionSetRepo->selectOrCreate($this->permissionSetFactory->createFromString(
$uid, $uid,
DI::aclFormatter()->toString($profileFieldInput['contact_allow'] ?? ''), $this->aclFormatter->toString($profileFieldInput['contact_allow'] ?? ''),
DI::aclFormatter()->toString($profileFieldInput['circle_allow'] ?? ''), $this->aclFormatter->toString($profileFieldInput['circle_allow'] ?? ''),
DI::aclFormatter()->toString($profileFieldInput['contact_deny'] ?? ''), $this->aclFormatter->toString($profileFieldInput['contact_deny'] ?? ''),
DI::aclFormatter()->toString($profileFieldInput['circle_deny'] ?? '') $this->aclFormatter->toString($profileFieldInput['circle_deny'] ?? '')
)); ));
$profileFields->append(DI::profileFieldFactory()->createFromValues( $profileFields->append($this->profileFieldFactory->createFromValues(
$uid, $uid,
$profileFieldOrder[$id], $profileFieldOrder[$id],
$profileFieldInput['label'], $profileFieldInput['label'],
@ -322,22 +353,20 @@ class Index extends BaseSettings
return $profileFields; return $profileFields;
} }
private static function cleanKeywords($keywords) private static function cleanKeywords($keywords): string
{ {
$keywords = str_replace(',', ' ', $keywords); $keywords = str_replace(',', ' ', $keywords);
$keywords = explode(' ', $keywords); $keywords = explode(' ', $keywords);
$cleaned = []; $cleaned = [];
foreach ($keywords as $keyword) { foreach ($keywords as $keyword) {
$keyword = trim(strtolower($keyword)); $keyword = trim($keyword);
$keyword = trim($keyword, '#'); $keyword = trim($keyword, '#');
if ($keyword != '') { if ($keyword != '') {
$cleaned[] = $keyword; $cleaned[] = $keyword;
} }
} }
$keywords = implode(', ', $cleaned); return implode(', ', $cleaned);
return $keywords;
} }
} }

View file

@ -211,7 +211,7 @@ class PermissionSet extends BaseRepository
} }
/** /**
* Selects or creates a PermissionSet based on it's fields * Selects or creates a PermissionSet based on its fields
* *
* @param Entity\PermissionSet $permissionSet * @param Entity\PermissionSet $permissionSet
* *

View file

@ -56,7 +56,7 @@ use Friendica\Database\DBA;
// This file is required several times during the test in DbaDefinition which justifies this condition // This file is required several times during the test in DbaDefinition which justifies this condition
if (!defined('DB_UPDATE_VERSION')) { if (!defined('DB_UPDATE_VERSION')) {
define('DB_UPDATE_VERSION', 1524); define('DB_UPDATE_VERSION', 1525);
} }
return [ return [
@ -1583,7 +1583,7 @@ return [
"profile-name" => ["type" => "varchar(255)", "comment" => "Deprecated"], "profile-name" => ["type" => "varchar(255)", "comment" => "Deprecated"],
"is-default" => ["type" => "boolean", "comment" => "Deprecated"], "is-default" => ["type" => "boolean", "comment" => "Deprecated"],
"hide-friends" => ["type" => "boolean", "not null" => "1", "default" => "0", "comment" => "Hide friend list from viewers of this profile"], "hide-friends" => ["type" => "boolean", "not null" => "1", "default" => "0", "comment" => "Hide friend list from viewers of this profile"],
"name" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""], "name" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => "Unused in favor of user.username"],
"pdesc" => ["type" => "varchar(255)", "comment" => "Deprecated"], "pdesc" => ["type" => "varchar(255)", "comment" => "Deprecated"],
"dob" => ["type" => "varchar(32)", "not null" => "1", "default" => "0000-00-00", "comment" => "Day of birth"], "dob" => ["type" => "varchar(32)", "not null" => "1", "default" => "0000-00-00", "comment" => "Day of birth"],
"address" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""], "address" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""],

View file

@ -1349,3 +1349,30 @@ function update_1524(): int
return Update::SUCCESS; return Update::SUCCESS;
} }
function update_1525(): int
{
// Use expected value for user.username
if (!DBA::e('UPDATE `user` u
JOIN `profile` p
ON p.`uid` = u.`uid`
SET u.`username` = p.`name`')) {
return Update::FAILED;
}
// Blank out deprecated field profile.name to avoid future confusion
if (!DBA::e('UPDATE `profile` p
SET p.`name` = ""')) {
return Update::FAILED;
}
// Update users' self-contact name if needed
if (!DBA::e('UPDATE `contact` c
JOIN `user` u
ON u.`uid` = c.`uid` AND c.`self` = 1
SET c.`name` = u.`username`')) {
return Update::FAILED;
}
return Update::SUCCESS;
}

View file

@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: 2023.09-dev\n" "Project-Id-Version: 2023.09-dev\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-08-10 21:16+0000\n" "POT-Creation-Date: 2023-08-11 01:11+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
@ -38,13 +38,13 @@ msgstr ""
msgid "Empty post discarded." msgid "Empty post discarded."
msgstr "" msgstr ""
#: mod/item.php:427 src/Module/Admin/Themes/Details.php:39 #: mod/item.php:428 src/Module/Admin/Themes/Details.php:39
#: src/Module/Admin/Themes/Index.php:59 src/Module/Debug/ItemBody.php:42 #: src/Module/Admin/Themes/Index.php:59 src/Module/Debug/ItemBody.php:42
#: src/Module/Debug/ItemBody.php:57 src/Module/Item/Feed.php:80 #: src/Module/Debug/ItemBody.php:57 src/Module/Item/Feed.php:80
msgid "Item not found." msgid "Item not found."
msgstr "" msgstr ""
#: mod/item.php:451 mod/message.php:67 mod/message.php:113 mod/notes.php:45 #: mod/item.php:452 mod/message.php:67 mod/message.php:113 mod/notes.php:45
#: mod/photos.php:152 mod/photos.php:670 src/Model/Event.php:520 #: mod/photos.php:152 mod/photos.php:670 src/Model/Event.php:520
#: src/Module/Attach.php:55 src/Module/BaseApi.php:99 #: src/Module/Attach.php:55 src/Module/BaseApi.php:99
#: src/Module/BaseNotifications.php:98 src/Module/BaseSettings.php:52 #: src/Module/BaseNotifications.php:98 src/Module/BaseSettings.php:52
@ -315,7 +315,7 @@ msgstr ""
#: src/Module/Moderation/Report/Create.php:211 #: src/Module/Moderation/Report/Create.php:211
#: src/Module/Moderation/Report/Create.php:263 #: src/Module/Moderation/Report/Create.php:263
#: src/Module/Profile/Profile.php:274 src/Module/Profile/UnkMail.php:155 #: src/Module/Profile/Profile.php:274 src/Module/Profile/UnkMail.php:155
#: src/Module/Settings/Profile/Index.php:230 src/Object/Post.php:1087 #: src/Module/Settings/Profile/Index.php:257 src/Object/Post.php:1087
#: view/theme/duepuntozero/config.php:85 view/theme/frio/config.php:171 #: view/theme/duepuntozero/config.php:85 view/theme/frio/config.php:171
#: view/theme/quattro/config.php:87 view/theme/vier/config.php:135 #: view/theme/quattro/config.php:87 view/theme/vier/config.php:135
msgid "Submit" msgid "Submit"
@ -388,7 +388,7 @@ msgid "Save"
msgstr "" msgstr ""
#: mod/photos.php:67 mod/photos.php:132 mod/photos.php:578 #: mod/photos.php:67 mod/photos.php:132 mod/photos.php:578
#: src/Model/Event.php:512 src/Model/Profile.php:234 #: src/Model/Event.php:512 src/Model/Profile.php:232
#: src/Module/Calendar/Export.php:74 src/Module/Calendar/Show.php:74 #: src/Module/Calendar/Export.php:74 src/Module/Calendar/Show.php:74
#: src/Module/DFRN/Poll.php:43 src/Module/Feed.php:65 src/Module/HCard.php:51 #: src/Module/DFRN/Poll.php:43 src/Module/Feed.php:65 src/Module/HCard.php:51
#: src/Module/Profile/Common.php:62 src/Module/Profile/Common.php:71 #: src/Module/Profile/Common.php:62 src/Module/Profile/Common.php:71
@ -779,17 +779,17 @@ msgstr ""
msgid "All contacts" msgid "All contacts"
msgstr "" msgstr ""
#: src/BaseModule.php:433 src/Content/Widget.php:243 src/Core/ACL.php:195 #: src/BaseModule.php:433 src/Content/Widget.php:239 src/Core/ACL.php:195
#: src/Module/Contact.php:415 src/Module/PermissionTooltip.php:127 #: src/Module/Contact.php:415 src/Module/PermissionTooltip.php:127
#: src/Module/PermissionTooltip.php:149 #: src/Module/PermissionTooltip.php:149
msgid "Followers" msgid "Followers"
msgstr "" msgstr ""
#: src/BaseModule.php:438 src/Content/Widget.php:244 src/Module/Contact.php:418 #: src/BaseModule.php:438 src/Content/Widget.php:240 src/Module/Contact.php:418
msgid "Following" msgid "Following"
msgstr "" msgstr ""
#: src/BaseModule.php:443 src/Content/Widget.php:245 src/Module/Contact.php:421 #: src/BaseModule.php:443 src/Content/Widget.php:241 src/Module/Contact.php:421
msgid "Mutual friends" msgid "Mutual friends"
msgstr "" msgstr ""
@ -943,7 +943,7 @@ msgstr ""
msgid "Enter user nickname: " msgid "Enter user nickname: "
msgstr "" msgstr ""
#: src/Console/User.php:182 src/Model/User.php:692 #: src/Console/User.php:182 src/Model/User.php:693
#: src/Module/Api/Twitter/ContactEndpoint.php:74 #: src/Module/Api/Twitter/ContactEndpoint.php:74
#: src/Module/Moderation/Users/Active.php:71 #: src/Module/Moderation/Users/Active.php:71
#: src/Module/Moderation/Users/Blocked.php:71 #: src/Module/Moderation/Users/Blocked.php:71
@ -1364,7 +1364,7 @@ msgid "Public post"
msgstr "" msgstr ""
#: src/Content/Conversation.php:417 src/Content/Widget/VCard.php:120 #: src/Content/Conversation.php:417 src/Content/Widget/VCard.php:120
#: src/Model/Profile.php:469 src/Module/Admin/Logs/View.php:92 #: src/Model/Profile.php:467 src/Module/Admin/Logs/View.php:92
#: src/Module/Post/Edit.php:181 #: src/Module/Post/Edit.php:181
msgid "Message" msgid "Message"
msgstr "" msgstr ""
@ -1607,8 +1607,8 @@ msgid ""
msgstr "" msgstr ""
#: src/Content/GroupManager.php:152 src/Content/Nav.php:276 #: src/Content/GroupManager.php:152 src/Content/Nav.php:276
#: src/Content/Text/HTML.php:880 src/Content/Widget.php:541 #: src/Content/Text/HTML.php:880 src/Content/Widget.php:537
#: src/Model/User.php:1254 #: src/Model/User.php:1255
msgid "Groups" msgid "Groups"
msgstr "" msgstr ""
@ -1616,12 +1616,12 @@ msgstr ""
msgid "External link to group" msgid "External link to group"
msgstr "" msgstr ""
#: src/Content/GroupManager.php:158 src/Content/Widget.php:516 #: src/Content/GroupManager.php:158 src/Content/Widget.php:512
msgid "show less" msgid "show less"
msgstr "" msgstr ""
#: src/Content/GroupManager.php:159 src/Content/Widget.php:414 #: src/Content/GroupManager.php:159 src/Content/Widget.php:410
#: src/Content/Widget.php:517 #: src/Content/Widget.php:513
msgid "show more" msgid "show more"
msgstr "" msgstr ""
@ -1629,7 +1629,7 @@ msgstr ""
msgid "Create new group" msgid "Create new group"
msgstr "" msgstr ""
#: src/Content/Item.php:329 src/Model/Item.php:2993 #: src/Content/Item.php:329 src/Model/Item.php:2998
msgid "event" msgid "event"
msgstr "" msgstr ""
@ -1637,7 +1637,7 @@ msgstr ""
msgid "status" msgid "status"
msgstr "" msgstr ""
#: src/Content/Item.php:338 src/Model/Item.php:2995 #: src/Content/Item.php:338 src/Model/Item.php:3000
#: src/Module/Post/Tag/Add.php:123 #: src/Module/Post/Tag/Add.php:123
msgid "photo" msgid "photo"
msgstr "" msgstr ""
@ -1651,31 +1651,31 @@ msgstr ""
msgid "Follow Thread" msgid "Follow Thread"
msgstr "" msgstr ""
#: src/Content/Item.php:422 src/Model/Contact.php:1205 #: src/Content/Item.php:422 src/Model/Contact.php:1210
msgid "View Status" msgid "View Status"
msgstr "" msgstr ""
#: src/Content/Item.php:423 src/Content/Item.php:443 src/Model/Contact.php:1154 #: src/Content/Item.php:423 src/Content/Item.php:443 src/Model/Contact.php:1159
#: src/Model/Contact.php:1197 src/Model/Contact.php:1206 #: src/Model/Contact.php:1202 src/Model/Contact.php:1211
#: src/Module/Directory.php:157 src/Module/Settings/Profile/Index.php:233 #: src/Module/Directory.php:157 src/Module/Settings/Profile/Index.php:259
msgid "View Profile" msgid "View Profile"
msgstr "" msgstr ""
#: src/Content/Item.php:424 src/Model/Contact.php:1207 #: src/Content/Item.php:424 src/Model/Contact.php:1212
msgid "View Photos" msgid "View Photos"
msgstr "" msgstr ""
#: src/Content/Item.php:425 src/Model/Contact.php:1198 #: src/Content/Item.php:425 src/Model/Contact.php:1203
#: src/Model/Contact.php:1208 #: src/Model/Contact.php:1213
msgid "Network Posts" msgid "Network Posts"
msgstr "" msgstr ""
#: src/Content/Item.php:426 src/Model/Contact.php:1199 #: src/Content/Item.php:426 src/Model/Contact.php:1204
#: src/Model/Contact.php:1209 #: src/Model/Contact.php:1214
msgid "View Contact" msgid "View Contact"
msgstr "" msgstr ""
#: src/Content/Item.php:427 src/Model/Contact.php:1210 #: src/Content/Item.php:427 src/Model/Contact.php:1215
msgid "Send PM" msgid "Send PM"
msgstr "" msgstr ""
@ -1705,7 +1705,7 @@ msgid "Languages"
msgstr "" msgstr ""
#: src/Content/Item.php:440 src/Content/Widget.php:80 #: src/Content/Item.php:440 src/Content/Widget.php:80
#: src/Model/Contact.php:1200 src/Model/Contact.php:1211 #: src/Model/Contact.php:1205 src/Model/Contact.php:1216
#: src/Module/Contact/Follow.php:167 view/theme/vier/theme.php:195 #: src/Module/Contact/Follow.php:167 view/theme/vier/theme.php:195
msgid "Connect/Follow" msgid "Connect/Follow"
msgstr "" msgstr ""
@ -2043,8 +2043,8 @@ msgid ""
"<a href=\"%1$s\" target=\"_blank\" rel=\"noopener noreferrer\">%2$s</a> %3$s" "<a href=\"%1$s\" target=\"_blank\" rel=\"noopener noreferrer\">%2$s</a> %3$s"
msgstr "" msgstr ""
#: src/Content/Text/BBCode.php:939 src/Model/Item.php:3735 #: src/Content/Text/BBCode.php:939 src/Model/Item.php:3740
#: src/Model/Item.php:3741 src/Model/Item.php:3742 #: src/Model/Item.php:3746 src/Model/Item.php:3747
msgid "Link to source" msgid "Link to source"
msgstr "" msgstr ""
@ -2077,7 +2077,7 @@ msgid "The end"
msgstr "" msgstr ""
#: src/Content/Text/HTML.php:859 src/Content/Widget/VCard.php:116 #: src/Content/Text/HTML.php:859 src/Content/Widget/VCard.php:116
#: src/Model/Profile.php:463 src/Module/Contact/Profile.php:437 #: src/Model/Profile.php:461 src/Module/Contact/Profile.php:437
msgid "Follow" msgid "Follow"
msgstr "" msgstr ""
@ -2147,80 +2147,80 @@ msgstr ""
msgid "Local Directory" msgid "Local Directory"
msgstr "" msgstr ""
#: src/Content/Widget.php:219 src/Model/Circle.php:600 #: src/Content/Widget.php:215 src/Model/Circle.php:600
#: src/Module/Contact.php:401 src/Module/Welcome.php:76 #: src/Module/Contact.php:401 src/Module/Welcome.php:76
msgid "Circles" msgid "Circles"
msgstr "" msgstr ""
#: src/Content/Widget.php:221 #: src/Content/Widget.php:217
msgid "Everyone" msgid "Everyone"
msgstr "" msgstr ""
#: src/Content/Widget.php:246 src/Module/Contact.php:424 #: src/Content/Widget.php:242 src/Module/Contact.php:424
msgid "No relationship" msgid "No relationship"
msgstr "" msgstr ""
#: src/Content/Widget.php:251 #: src/Content/Widget.php:247
msgid "Relationships" msgid "Relationships"
msgstr "" msgstr ""
#: src/Content/Widget.php:253 src/Module/Circle.php:292 #: src/Content/Widget.php:249 src/Module/Circle.php:292
#: src/Module/Contact.php:345 #: src/Module/Contact.php:345
msgid "All Contacts" msgid "All Contacts"
msgstr "" msgstr ""
#: src/Content/Widget.php:292 #: src/Content/Widget.php:288
msgid "Protocols" msgid "Protocols"
msgstr "" msgstr ""
#: src/Content/Widget.php:294 #: src/Content/Widget.php:290
msgid "All Protocols" msgid "All Protocols"
msgstr "" msgstr ""
#: src/Content/Widget.php:322 #: src/Content/Widget.php:318
msgid "Saved Folders" msgid "Saved Folders"
msgstr "" msgstr ""
#: src/Content/Widget.php:324 src/Content/Widget.php:355 #: src/Content/Widget.php:320 src/Content/Widget.php:351
msgid "Everything" msgid "Everything"
msgstr "" msgstr ""
#: src/Content/Widget.php:353 #: src/Content/Widget.php:349
msgid "Categories" msgid "Categories"
msgstr "" msgstr ""
#: src/Content/Widget.php:410 #: src/Content/Widget.php:406
#, php-format #, php-format
msgid "%d contact in common" msgid "%d contact in common"
msgid_plural "%d contacts in common" msgid_plural "%d contacts in common"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Content/Widget.php:510 #: src/Content/Widget.php:506
msgid "Archives" msgid "Archives"
msgstr "" msgstr ""
#: src/Content/Widget.php:518 #: src/Content/Widget.php:514
msgid "On this date" msgid "On this date"
msgstr "" msgstr ""
#: src/Content/Widget.php:538 #: src/Content/Widget.php:534
msgid "Persons" msgid "Persons"
msgstr "" msgstr ""
#: src/Content/Widget.php:539 #: src/Content/Widget.php:535
msgid "Organisations" msgid "Organisations"
msgstr "" msgstr ""
#: src/Content/Widget.php:540 src/Model/Contact.php:1675 #: src/Content/Widget.php:536 src/Model/Contact.php:1680
msgid "News" msgid "News"
msgstr "" msgstr ""
#: src/Content/Widget.php:546 src/Module/Settings/Account.php:454 #: src/Content/Widget.php:542 src/Module/Settings/Account.php:454
msgid "Account Types" msgid "Account Types"
msgstr "" msgstr ""
#: src/Content/Widget.php:548 src/Module/Moderation/BaseUsers.php:69 #: src/Content/Widget.php:544 src/Module/Moderation/BaseUsers.php:69
msgid "All" msgid "All"
msgstr "" msgstr ""
@ -2270,31 +2270,31 @@ msgstr[1] ""
msgid "More Trending Tags" msgid "More Trending Tags"
msgstr "" msgstr ""
#: src/Content/Widget/VCard.php:109 src/Model/Profile.php:378 #: src/Content/Widget/VCard.php:109 src/Model/Profile.php:376
#: src/Module/Contact/Profile.php:381 src/Module/Profile/Profile.php:199 #: src/Module/Contact/Profile.php:381 src/Module/Profile/Profile.php:199
msgid "XMPP:" msgid "XMPP:"
msgstr "" msgstr ""
#: src/Content/Widget/VCard.php:110 src/Model/Profile.php:379 #: src/Content/Widget/VCard.php:110 src/Model/Profile.php:377
#: src/Module/Contact/Profile.php:383 src/Module/Profile/Profile.php:203 #: src/Module/Contact/Profile.php:383 src/Module/Profile/Profile.php:203
msgid "Matrix:" msgid "Matrix:"
msgstr "" msgstr ""
#: src/Content/Widget/VCard.php:111 src/Model/Event.php:82 #: src/Content/Widget/VCard.php:111 src/Model/Event.php:82
#: src/Model/Event.php:109 src/Model/Event.php:471 src/Model/Event.php:963 #: src/Model/Event.php:109 src/Model/Event.php:471 src/Model/Event.php:963
#: src/Model/Profile.php:373 src/Module/Contact/Profile.php:379 #: src/Model/Profile.php:371 src/Module/Contact/Profile.php:379
#: src/Module/Directory.php:147 src/Module/Notifications/Introductions.php:187 #: src/Module/Directory.php:147 src/Module/Notifications/Introductions.php:187
#: src/Module/Profile/Profile.php:221 #: src/Module/Profile/Profile.php:221
msgid "Location:" msgid "Location:"
msgstr "" msgstr ""
#: src/Content/Widget/VCard.php:114 src/Model/Profile.php:476 #: src/Content/Widget/VCard.php:114 src/Model/Profile.php:474
#: src/Module/Notifications/Introductions.php:201 #: src/Module/Notifications/Introductions.php:201
msgid "Network:" msgid "Network:"
msgstr "" msgstr ""
#: src/Content/Widget/VCard.php:118 src/Model/Contact.php:1201 #: src/Content/Widget/VCard.php:118 src/Model/Contact.php:1206
#: src/Model/Contact.php:1212 src/Model/Profile.php:465 #: src/Model/Contact.php:1217 src/Model/Profile.php:463
#: src/Module/Contact/Profile.php:429 #: src/Module/Contact/Profile.php:429
msgid "Unfollow" msgid "Unfollow"
msgstr "" msgstr ""
@ -3047,82 +3047,82 @@ msgstr ""
msgid "Edit circles" msgid "Edit circles"
msgstr "" msgstr ""
#: src/Model/Contact.php:1218 src/Module/Moderation/Users/Pending.php:102 #: src/Model/Contact.php:1223 src/Module/Moderation/Users/Pending.php:102
#: src/Module/Notifications/Introductions.php:132 #: src/Module/Notifications/Introductions.php:132
#: src/Module/Notifications/Introductions.php:204 #: src/Module/Notifications/Introductions.php:204
msgid "Approve" msgid "Approve"
msgstr "" msgstr ""
#: src/Model/Contact.php:1671 #: src/Model/Contact.php:1676
msgid "Organisation" msgid "Organisation"
msgstr "" msgstr ""
#: src/Model/Contact.php:1679 #: src/Model/Contact.php:1684
msgid "Group" msgid "Group"
msgstr "" msgstr ""
#: src/Model/Contact.php:2988 #: src/Model/Contact.php:2993
msgid "Disallowed profile URL." msgid "Disallowed profile URL."
msgstr "" msgstr ""
#: src/Model/Contact.php:2993 src/Module/Friendica.php:102 #: src/Model/Contact.php:2998 src/Module/Friendica.php:102
msgid "Blocked domain" msgid "Blocked domain"
msgstr "" msgstr ""
#: src/Model/Contact.php:2998 #: src/Model/Contact.php:3003
msgid "Connect URL missing." msgid "Connect URL missing."
msgstr "" msgstr ""
#: src/Model/Contact.php:3007 #: src/Model/Contact.php:3012
msgid "" msgid ""
"The contact could not be added. Please check the relevant network " "The contact could not be added. Please check the relevant network "
"credentials in your Settings -> Social Networks page." "credentials in your Settings -> Social Networks page."
msgstr "" msgstr ""
#: src/Model/Contact.php:3025 #: src/Model/Contact.php:3030
#, php-format #, php-format
msgid "Expected network %s does not match actual network %s" msgid "Expected network %s does not match actual network %s"
msgstr "" msgstr ""
#: src/Model/Contact.php:3042 #: src/Model/Contact.php:3047
msgid "The profile address specified does not provide adequate information." msgid "The profile address specified does not provide adequate information."
msgstr "" msgstr ""
#: src/Model/Contact.php:3044 #: src/Model/Contact.php:3049
msgid "No compatible communication protocols or feeds were discovered." msgid "No compatible communication protocols or feeds were discovered."
msgstr "" msgstr ""
#: src/Model/Contact.php:3047 #: src/Model/Contact.php:3052
msgid "An author or name was not found." msgid "An author or name was not found."
msgstr "" msgstr ""
#: src/Model/Contact.php:3050 #: src/Model/Contact.php:3055
msgid "No browser URL could be matched to this address." msgid "No browser URL could be matched to this address."
msgstr "" msgstr ""
#: src/Model/Contact.php:3053 #: src/Model/Contact.php:3058
msgid "" msgid ""
"Unable to match @-style Identity Address with a known protocol or email " "Unable to match @-style Identity Address with a known protocol or email "
"contact." "contact."
msgstr "" msgstr ""
#: src/Model/Contact.php:3054 #: src/Model/Contact.php:3059
msgid "Use mailto: in front of address to force email check." msgid "Use mailto: in front of address to force email check."
msgstr "" msgstr ""
#: src/Model/Contact.php:3060 #: src/Model/Contact.php:3065
msgid "" msgid ""
"The profile address specified belongs to a network which has been disabled " "The profile address specified belongs to a network which has been disabled "
"on this site." "on this site."
msgstr "" msgstr ""
#: src/Model/Contact.php:3065 #: src/Model/Contact.php:3070
msgid "" msgid ""
"Limited profile. This person will be unable to receive direct/personal " "Limited profile. This person will be unable to receive direct/personal "
"notifications from you." "notifications from you."
msgstr "" msgstr ""
#: src/Model/Contact.php:3131 #: src/Model/Contact.php:3136
msgid "Unable to retrieve contact information." msgid "Unable to retrieve contact information."
msgstr "" msgstr ""
@ -3227,81 +3227,81 @@ msgstr ""
msgid "Happy Birthday %s" msgid "Happy Birthday %s"
msgstr "" msgstr ""
#: src/Model/Item.php:2056 #: src/Model/Item.php:2057
#, php-format #, php-format
msgid "Detected languages in this post:\\n%s" msgid "Detected languages in this post:\\n%s"
msgstr "" msgstr ""
#: src/Model/Item.php:2997 #: src/Model/Item.php:3002
msgid "activity" msgid "activity"
msgstr "" msgstr ""
#: src/Model/Item.php:2999 #: src/Model/Item.php:3004
msgid "comment" msgid "comment"
msgstr "" msgstr ""
#: src/Model/Item.php:3002 src/Module/Post/Tag/Add.php:123 #: src/Model/Item.php:3007 src/Module/Post/Tag/Add.php:123
msgid "post" msgid "post"
msgstr "" msgstr ""
#: src/Model/Item.php:3172 #: src/Model/Item.php:3177
#, php-format #, php-format
msgid "%s is blocked" msgid "%s is blocked"
msgstr "" msgstr ""
#: src/Model/Item.php:3174 #: src/Model/Item.php:3179
#, php-format #, php-format
msgid "%s is ignored" msgid "%s is ignored"
msgstr "" msgstr ""
#: src/Model/Item.php:3176 #: src/Model/Item.php:3181
#, php-format #, php-format
msgid "Content from %s is collapsed" msgid "Content from %s is collapsed"
msgstr "" msgstr ""
#: src/Model/Item.php:3180 #: src/Model/Item.php:3185
#, php-format #, php-format
msgid "Content warning: %s" msgid "Content warning: %s"
msgstr "" msgstr ""
#: src/Model/Item.php:3642 #: src/Model/Item.php:3647
msgid "bytes" msgid "bytes"
msgstr "" msgstr ""
#: src/Model/Item.php:3673 #: src/Model/Item.php:3678
#, php-format #, php-format
msgid "%2$s (%3$d%%, %1$d vote)" msgid "%2$s (%3$d%%, %1$d vote)"
msgid_plural "%2$s (%3$d%%, %1$d votes)" msgid_plural "%2$s (%3$d%%, %1$d votes)"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Model/Item.php:3675 #: src/Model/Item.php:3680
#, php-format #, php-format
msgid "%2$s (%1$d vote)" msgid "%2$s (%1$d vote)"
msgid_plural "%2$s (%1$d votes)" msgid_plural "%2$s (%1$d votes)"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Model/Item.php:3680 #: src/Model/Item.php:3685
#, php-format #, php-format
msgid "%d voter. Poll end: %s" msgid "%d voter. Poll end: %s"
msgid_plural "%d voters. Poll end: %s" msgid_plural "%d voters. Poll end: %s"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Model/Item.php:3682 #: src/Model/Item.php:3687
#, php-format #, php-format
msgid "%d voter." msgid "%d voter."
msgid_plural "%d voters." msgid_plural "%d voters."
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Model/Item.php:3684 #: src/Model/Item.php:3689
#, php-format #, php-format
msgid "Poll end: %s" msgid "Poll end: %s"
msgstr "" msgstr ""
#: src/Model/Item.php:3718 src/Model/Item.php:3719 #: src/Model/Item.php:3723 src/Model/Item.php:3724
msgid "View on separate page" msgid "View on separate page"
msgstr "" msgstr ""
@ -3309,295 +3309,295 @@ msgstr ""
msgid "[no subject]" msgid "[no subject]"
msgstr "" msgstr ""
#: src/Model/Photo.php:1184 src/Module/Media/Photo/Upload.php:170 #: src/Model/Photo.php:1190 src/Module/Media/Photo/Upload.php:170
msgid "Wall Photos" msgid "Wall Photos"
msgstr "" msgstr ""
#: src/Model/Profile.php:361 src/Module/Profile/Profile.php:283 #: src/Model/Profile.php:359 src/Module/Profile/Profile.php:283
#: src/Module/Profile/Profile.php:285 #: src/Module/Profile/Profile.php:285
msgid "Edit profile" msgid "Edit profile"
msgstr "" msgstr ""
#: src/Model/Profile.php:363 #: src/Model/Profile.php:361
msgid "Change profile photo" msgid "Change profile photo"
msgstr "" msgstr ""
#: src/Model/Profile.php:376 src/Module/Directory.php:152 #: src/Model/Profile.php:374 src/Module/Directory.php:152
#: src/Module/Profile/Profile.php:209 #: src/Module/Profile/Profile.php:209
msgid "Homepage:" msgid "Homepage:"
msgstr "" msgstr ""
#: src/Model/Profile.php:377 src/Module/Contact/Profile.php:385 #: src/Model/Profile.php:375 src/Module/Contact/Profile.php:385
#: src/Module/Notifications/Introductions.php:189 #: src/Module/Notifications/Introductions.php:189
msgid "About:" msgid "About:"
msgstr "" msgstr ""
#: src/Model/Profile.php:467 #: src/Model/Profile.php:465
msgid "Atom feed" msgid "Atom feed"
msgstr "" msgstr ""
#: src/Model/Profile.php:474 #: src/Model/Profile.php:472
msgid "This website has been verified to belong to the same person." msgid "This website has been verified to belong to the same person."
msgstr "" msgstr ""
#: src/Model/Profile.php:511 #: src/Model/Profile.php:509
msgid "F d" msgid "F d"
msgstr "" msgstr ""
#: src/Model/Profile.php:575 src/Model/Profile.php:664 #: src/Model/Profile.php:573 src/Model/Profile.php:662
msgid "[today]" msgid "[today]"
msgstr "" msgstr ""
#: src/Model/Profile.php:584 #: src/Model/Profile.php:582
msgid "Birthday Reminders" msgid "Birthday Reminders"
msgstr "" msgstr ""
#: src/Model/Profile.php:585 #: src/Model/Profile.php:583
msgid "Birthdays this week:" msgid "Birthdays this week:"
msgstr "" msgstr ""
#: src/Model/Profile.php:613 #: src/Model/Profile.php:611
msgid "g A l F d" msgid "g A l F d"
msgstr "" msgstr ""
#: src/Model/Profile.php:651 #: src/Model/Profile.php:649
msgid "[No description]" msgid "[No description]"
msgstr "" msgstr ""
#: src/Model/Profile.php:677 #: src/Model/Profile.php:675
msgid "Event Reminders" msgid "Event Reminders"
msgstr "" msgstr ""
#: src/Model/Profile.php:678 #: src/Model/Profile.php:676
msgid "Upcoming events the next 7 days:" msgid "Upcoming events the next 7 days:"
msgstr "" msgstr ""
#: src/Model/Profile.php:875 #: src/Model/Profile.php:873
#, php-format #, php-format
msgid "OpenWebAuth: %1$s welcomes %2$s" msgid "OpenWebAuth: %1$s welcomes %2$s"
msgstr "" msgstr ""
#: src/Model/Profile.php:1015 #: src/Model/Profile.php:1013
msgid "Hometown:" msgid "Hometown:"
msgstr "" msgstr ""
#: src/Model/Profile.php:1016 #: src/Model/Profile.php:1014
msgid "Marital Status:" msgid "Marital Status:"
msgstr "" msgstr ""
#: src/Model/Profile.php:1017 #: src/Model/Profile.php:1015
msgid "With:" msgid "With:"
msgstr "" msgstr ""
#: src/Model/Profile.php:1018 #: src/Model/Profile.php:1016
msgid "Since:" msgid "Since:"
msgstr "" msgstr ""
#: src/Model/Profile.php:1019 #: src/Model/Profile.php:1017
msgid "Sexual Preference:" msgid "Sexual Preference:"
msgstr "" msgstr ""
#: src/Model/Profile.php:1020 #: src/Model/Profile.php:1018
msgid "Political Views:" msgid "Political Views:"
msgstr "" msgstr ""
#: src/Model/Profile.php:1021 #: src/Model/Profile.php:1019
msgid "Religious Views:" msgid "Religious Views:"
msgstr "" msgstr ""
#: src/Model/Profile.php:1022 #: src/Model/Profile.php:1020
msgid "Likes:" msgid "Likes:"
msgstr "" msgstr ""
#: src/Model/Profile.php:1023 #: src/Model/Profile.php:1021
msgid "Dislikes:" msgid "Dislikes:"
msgstr "" msgstr ""
#: src/Model/Profile.php:1024 #: src/Model/Profile.php:1022
msgid "Title/Description:" msgid "Title/Description:"
msgstr "" msgstr ""
#: src/Model/Profile.php:1025 src/Module/Admin/Summary.php:197 #: src/Model/Profile.php:1023 src/Module/Admin/Summary.php:197
#: src/Module/Moderation/Report/Create.php:280 #: src/Module/Moderation/Report/Create.php:280
#: src/Module/Moderation/Summary.php:77 #: src/Module/Moderation/Summary.php:77
msgid "Summary" msgid "Summary"
msgstr "" msgstr ""
#: src/Model/Profile.php:1026 #: src/Model/Profile.php:1024
msgid "Musical interests" msgid "Musical interests"
msgstr "" msgstr ""
#: src/Model/Profile.php:1027 #: src/Model/Profile.php:1025
msgid "Books, literature" msgid "Books, literature"
msgstr "" msgstr ""
#: src/Model/Profile.php:1028 #: src/Model/Profile.php:1026
msgid "Television" msgid "Television"
msgstr "" msgstr ""
#: src/Model/Profile.php:1029 #: src/Model/Profile.php:1027
msgid "Film/dance/culture/entertainment" msgid "Film/dance/culture/entertainment"
msgstr "" msgstr ""
#: src/Model/Profile.php:1030 #: src/Model/Profile.php:1028
msgid "Hobbies/Interests" msgid "Hobbies/Interests"
msgstr "" msgstr ""
#: src/Model/Profile.php:1031 #: src/Model/Profile.php:1029
msgid "Love/romance" msgid "Love/romance"
msgstr "" msgstr ""
#: src/Model/Profile.php:1032 #: src/Model/Profile.php:1030
msgid "Work/employment" msgid "Work/employment"
msgstr "" msgstr ""
#: src/Model/Profile.php:1033 #: src/Model/Profile.php:1031
msgid "School/education" msgid "School/education"
msgstr "" msgstr ""
#: src/Model/Profile.php:1034 #: src/Model/Profile.php:1032
msgid "Contact information and Social Networks" msgid "Contact information and Social Networks"
msgstr "" msgstr ""
#: src/Model/User.php:225 src/Model/User.php:1167 #: src/Model/User.php:226 src/Model/User.php:1168
msgid "SERIOUS ERROR: Generation of security keys failed." msgid "SERIOUS ERROR: Generation of security keys failed."
msgstr "" msgstr ""
#: src/Model/User.php:601 src/Model/User.php:634 #: src/Model/User.php:602 src/Model/User.php:635
msgid "Login failed" msgid "Login failed"
msgstr "" msgstr ""
#: src/Model/User.php:666 #: src/Model/User.php:667
msgid "Not enough information to authenticate" msgid "Not enough information to authenticate"
msgstr "" msgstr ""
#: src/Model/User.php:787 #: src/Model/User.php:788
msgid "Password can't be empty" msgid "Password can't be empty"
msgstr "" msgstr ""
#: src/Model/User.php:829 #: src/Model/User.php:830
msgid "Empty passwords are not allowed." msgid "Empty passwords are not allowed."
msgstr "" msgstr ""
#: src/Model/User.php:833 #: src/Model/User.php:834
msgid "" msgid ""
"The new password has been exposed in a public data dump, please choose " "The new password has been exposed in a public data dump, please choose "
"another." "another."
msgstr "" msgstr ""
#: src/Model/User.php:837 #: src/Model/User.php:838
msgid "The password length is limited to 72 characters." msgid "The password length is limited to 72 characters."
msgstr "" msgstr ""
#: src/Model/User.php:841 #: src/Model/User.php:842
msgid "The password can't contain white spaces nor accentuated letters" msgid "The password can't contain white spaces nor accentuated letters"
msgstr "" msgstr ""
#: src/Model/User.php:1050 #: src/Model/User.php:1051
msgid "Passwords do not match. Password unchanged." msgid "Passwords do not match. Password unchanged."
msgstr "" msgstr ""
#: src/Model/User.php:1057 #: src/Model/User.php:1058
msgid "An invitation is required." msgid "An invitation is required."
msgstr "" msgstr ""
#: src/Model/User.php:1061 #: src/Model/User.php:1062
msgid "Invitation could not be verified." msgid "Invitation could not be verified."
msgstr "" msgstr ""
#: src/Model/User.php:1069 #: src/Model/User.php:1070
msgid "Invalid OpenID url" msgid "Invalid OpenID url"
msgstr "" msgstr ""
#: src/Model/User.php:1082 src/Security/Authentication.php:241 #: src/Model/User.php:1083 src/Security/Authentication.php:241
msgid "" msgid ""
"We encountered a problem while logging in with the OpenID you provided. " "We encountered a problem while logging in with the OpenID you provided. "
"Please check the correct spelling of the ID." "Please check the correct spelling of the ID."
msgstr "" msgstr ""
#: src/Model/User.php:1082 src/Security/Authentication.php:241 #: src/Model/User.php:1083 src/Security/Authentication.php:241
msgid "The error message was:" msgid "The error message was:"
msgstr "" msgstr ""
#: src/Model/User.php:1088 #: src/Model/User.php:1089
msgid "Please enter the required information." msgid "Please enter the required information."
msgstr "" msgstr ""
#: src/Model/User.php:1102 #: src/Model/User.php:1103
#, php-format #, php-format
msgid "" msgid ""
"system.username_min_length (%s) and system.username_max_length (%s) are " "system.username_min_length (%s) and system.username_max_length (%s) are "
"excluding each other, swapping values." "excluding each other, swapping values."
msgstr "" msgstr ""
#: src/Model/User.php:1109 #: src/Model/User.php:1110
#, php-format #, php-format
msgid "Username should be at least %s character." msgid "Username should be at least %s character."
msgid_plural "Username should be at least %s characters." msgid_plural "Username should be at least %s characters."
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Model/User.php:1113 #: src/Model/User.php:1114
#, php-format #, php-format
msgid "Username should be at most %s character." msgid "Username should be at most %s character."
msgid_plural "Username should be at most %s characters." msgid_plural "Username should be at most %s characters."
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Model/User.php:1121 #: src/Model/User.php:1122
msgid "That doesn't appear to be your full (First Last) name." msgid "That doesn't appear to be your full (First Last) name."
msgstr "" msgstr ""
#: src/Model/User.php:1126 #: src/Model/User.php:1127
msgid "Your email domain is not among those allowed on this site." msgid "Your email domain is not among those allowed on this site."
msgstr "" msgstr ""
#: src/Model/User.php:1130 #: src/Model/User.php:1131
msgid "Not a valid email address." msgid "Not a valid email address."
msgstr "" msgstr ""
#: src/Model/User.php:1133 #: src/Model/User.php:1134
msgid "The nickname was blocked from registration by the nodes admin." msgid "The nickname was blocked from registration by the nodes admin."
msgstr "" msgstr ""
#: src/Model/User.php:1137 src/Model/User.php:1143 #: src/Model/User.php:1138 src/Model/User.php:1144
msgid "Cannot use that email." msgid "Cannot use that email."
msgstr "" msgstr ""
#: src/Model/User.php:1149 #: src/Model/User.php:1150
msgid "Your nickname can only contain a-z, 0-9 and _." msgid "Your nickname can only contain a-z, 0-9 and _."
msgstr "" msgstr ""
#: src/Model/User.php:1157 src/Model/User.php:1214 #: src/Model/User.php:1158 src/Model/User.php:1215
msgid "Nickname is already registered. Please choose another." msgid "Nickname is already registered. Please choose another."
msgstr "" msgstr ""
#: src/Model/User.php:1201 src/Model/User.php:1205 #: src/Model/User.php:1202 src/Model/User.php:1206
msgid "An error occurred during registration. Please try again." msgid "An error occurred during registration. Please try again."
msgstr "" msgstr ""
#: src/Model/User.php:1228 #: src/Model/User.php:1229
msgid "An error occurred creating your default profile. Please try again." msgid "An error occurred creating your default profile. Please try again."
msgstr "" msgstr ""
#: src/Model/User.php:1235 #: src/Model/User.php:1236
msgid "An error occurred creating your self contact. Please try again." msgid "An error occurred creating your self contact. Please try again."
msgstr "" msgstr ""
#: src/Model/User.php:1240 #: src/Model/User.php:1241
msgid "Friends" msgid "Friends"
msgstr "" msgstr ""
#: src/Model/User.php:1244 #: src/Model/User.php:1245
msgid "" msgid ""
"An error occurred creating your default contact circle. Please try again." "An error occurred creating your default contact circle. Please try again."
msgstr "" msgstr ""
#: src/Model/User.php:1288 #: src/Model/User.php:1289
msgid "Profile Photos" msgid "Profile Photos"
msgstr "" msgstr ""
#: src/Model/User.php:1483 #: src/Model/User.php:1469
#, php-format #, php-format
msgid "" msgid ""
"\n" "\n"
@ -3605,7 +3605,7 @@ msgid ""
"\t\t\tthe administrator of %2$s has set up an account for you." "\t\t\tthe administrator of %2$s has set up an account for you."
msgstr "" msgstr ""
#: src/Model/User.php:1486 #: src/Model/User.php:1472
#, php-format #, php-format
msgid "" msgid ""
"\n" "\n"
@ -3643,12 +3643,12 @@ msgid ""
"\t\tThank you and welcome to %4$s." "\t\tThank you and welcome to %4$s."
msgstr "" msgstr ""
#: src/Model/User.php:1519 src/Model/User.php:1626 #: src/Model/User.php:1505 src/Model/User.php:1612
#, php-format #, php-format
msgid "Registration details for %s" msgid "Registration details for %s"
msgstr "" msgstr ""
#: src/Model/User.php:1539 #: src/Model/User.php:1525
#, php-format #, php-format
msgid "" msgid ""
"\n" "\n"
@ -3664,12 +3664,12 @@ msgid ""
"\t\t" "\t\t"
msgstr "" msgstr ""
#: src/Model/User.php:1558 #: src/Model/User.php:1544
#, php-format #, php-format
msgid "Registration at %s" msgid "Registration at %s"
msgstr "" msgstr ""
#: src/Model/User.php:1582 #: src/Model/User.php:1568
#, php-format #, php-format
msgid "" msgid ""
"\n" "\n"
@ -3678,7 +3678,7 @@ msgid ""
"\t\t\t" "\t\t\t"
msgstr "" msgstr ""
#: src/Model/User.php:1590 #: src/Model/User.php:1576
#, php-format #, php-format
msgid "" msgid ""
"\n" "\n"
@ -6564,7 +6564,7 @@ msgid "Sort by post creation date"
msgstr "" msgstr ""
#: src/Module/Conversation/Network.php:281 #: src/Module/Conversation/Network.php:281
#: src/Module/Settings/Profile/Index.php:235 #: src/Module/Settings/Profile/Index.php:260
msgid "Personal" msgid "Personal"
msgstr "" msgstr ""
@ -6796,7 +6796,7 @@ msgid "Twitter Source / Tweet URL (requires API key)"
msgstr "" msgstr ""
#: src/Module/Debug/Feed.php:52 src/Module/Filer/SaveTag.php:47 #: src/Module/Debug/Feed.php:52 src/Module/Filer/SaveTag.php:47
#: src/Module/Settings/Profile/Index.php:144 #: src/Module/Settings/Profile/Index.php:177
msgid "You must be logged in to use this module" msgid "You must be logged in to use this module"
msgstr "" msgstr ""
@ -8586,20 +8586,20 @@ msgstr ""
#: src/Module/Profile/Conversations.php:106 #: src/Module/Profile/Conversations.php:106
#: src/Module/Profile/Conversations.php:109 src/Module/Profile/Profile.php:351 #: src/Module/Profile/Conversations.php:109 src/Module/Profile/Profile.php:351
#: src/Module/Profile/Profile.php:354 src/Protocol/Feed.php:1090 #: src/Module/Profile/Profile.php:354 src/Protocol/Feed.php:1098
#: src/Protocol/OStatus.php:1009 #: src/Protocol/OStatus.php:1009
#, php-format #, php-format
msgid "%s's timeline" msgid "%s's timeline"
msgstr "" msgstr ""
#: src/Module/Profile/Conversations.php:107 src/Module/Profile/Profile.php:352 #: src/Module/Profile/Conversations.php:107 src/Module/Profile/Profile.php:352
#: src/Protocol/Feed.php:1094 src/Protocol/OStatus.php:1014 #: src/Protocol/Feed.php:1102 src/Protocol/OStatus.php:1014
#, php-format #, php-format
msgid "%s's posts" msgid "%s's posts"
msgstr "" msgstr ""
#: src/Module/Profile/Conversations.php:108 src/Module/Profile/Profile.php:353 #: src/Module/Profile/Conversations.php:108 src/Module/Profile/Profile.php:353
#: src/Protocol/Feed.php:1097 src/Protocol/OStatus.php:1018 #: src/Protocol/Feed.php:1105 src/Protocol/OStatus.php:1018
#, php-format #, php-format
msgid "%s's comments" msgid "%s's comments"
msgstr "" msgstr ""
@ -8644,7 +8644,7 @@ msgid ""
"\"btn btn-sm pull-right\">Cancel</a>" "\"btn btn-sm pull-right\">Cancel</a>"
msgstr "" msgstr ""
#: src/Module/Profile/Profile.php:167 src/Module/Settings/Account.php:576 #: src/Module/Profile/Profile.php:167
msgid "Full Name:" msgid "Full Name:"
msgstr "" msgstr ""
@ -8664,12 +8664,12 @@ msgstr ""
msgid "Birthday:" msgid "Birthday:"
msgstr "" msgstr ""
#: src/Module/Profile/Profile.php:190 src/Module/Settings/Profile/Index.php:253 #: src/Module/Profile/Profile.php:190 src/Module/Settings/Profile/Index.php:291
#: src/Util/Temporal.php:170 #: src/Util/Temporal.php:170
msgid "Age: " msgid "Age: "
msgstr "" msgstr ""
#: src/Module/Profile/Profile.php:190 src/Module/Settings/Profile/Index.php:253 #: src/Module/Profile/Profile.php:190 src/Module/Settings/Profile/Index.php:291
#: src/Util/Temporal.php:170 #: src/Util/Temporal.php:170
#, php-format #, php-format
msgid "%d year old" msgid "%d year old"
@ -8677,7 +8677,7 @@ msgid_plural "%d years old"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
#: src/Module/Profile/Profile.php:195 src/Module/Settings/Profile/Index.php:246 #: src/Module/Profile/Profile.php:195 src/Module/Settings/Profile/Index.php:284
msgid "Description:" msgid "Description:"
msgstr "" msgstr ""
@ -9362,6 +9362,11 @@ msgstr ""
msgid "Basic Settings" msgid "Basic Settings"
msgstr "" msgstr ""
#: src/Module/Settings/Account.php:576
#: src/Module/Settings/Profile/Index.php:283
msgid "Display name:"
msgstr ""
#: src/Module/Settings/Account.php:577 #: src/Module/Settings/Account.php:577
msgid "Email Address:" msgid "Email Address:"
msgstr "" msgstr ""
@ -10126,146 +10131,85 @@ msgstr ""
msgid "Remove authorization" msgid "Remove authorization"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:84 #: src/Module/Settings/Profile/Index.php:116
msgid "Profile Name is required." msgid "Display Name is required."
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:134 #: src/Module/Settings/Profile/Index.php:167
msgid "Profile couldn't be updated." msgid "Profile couldn't be updated."
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:175 #: src/Module/Settings/Profile/Index.php:205
#: src/Module/Settings/Profile/Index.php:195 #: src/Module/Settings/Profile/Index.php:226
msgid "Label:" msgid "Label:"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:176 #: src/Module/Settings/Profile/Index.php:206
#: src/Module/Settings/Profile/Index.php:196 #: src/Module/Settings/Profile/Index.php:227
msgid "Value:" msgid "Value:"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:186 #: src/Module/Settings/Profile/Index.php:217
#: src/Module/Settings/Profile/Index.php:206 #: src/Module/Settings/Profile/Index.php:238
msgid "Field Permissions" msgid "Field Permissions"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:187 #: src/Module/Settings/Profile/Index.php:218
#: src/Module/Settings/Profile/Index.php:207 #: src/Module/Settings/Profile/Index.php:239
msgid "(click to open/close)" msgid "(click to open/close)"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:193 #: src/Module/Settings/Profile/Index.php:224
msgid "Add a new profile field" msgid "Add a new profile field"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:216 #: src/Module/Settings/Profile/Index.php:247
msgid "" msgid ""
"The homepage is verified. A rel=\"me\" link back to your Friendica profile " "The homepage is verified. A rel=\"me\" link back to your Friendica profile "
"page was found on the homepage." "page was found on the homepage."
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:218 #: src/Module/Settings/Profile/Index.php:249
#, php-format #, php-format
msgid "" msgid ""
"To verify your homepage, add a rel=\"me\" link to it, pointing to your " "To verify your homepage, add a rel=\"me\" link to it, pointing to your "
"profile URL (%s)." "profile URL (%s)."
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:228 #: src/Module/Settings/Profile/Index.php:255
msgid "Profile Actions" msgid "Profile Actions"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:229 #: src/Module/Settings/Profile/Index.php:256
msgid "Edit Profile Details" msgid "Edit Profile Details"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:231 #: src/Module/Settings/Profile/Index.php:258
msgid "Change Profile Photo" msgid "Change Profile Photo"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:236 #: src/Module/Settings/Profile/Index.php:261
msgid "Profile picture" msgid "Profile picture"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:237 #: src/Module/Settings/Profile/Index.php:262
msgid "Location" msgid "Location"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:238 src/Util/Temporal.php:97 #: src/Module/Settings/Profile/Index.php:263 src/Util/Temporal.php:97
#: src/Util/Temporal.php:99 #: src/Util/Temporal.php:99
msgid "Miscellaneous" msgid "Miscellaneous"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:239 #: src/Module/Settings/Profile/Index.php:264
msgid "Custom Profile Fields" msgid "Custom Profile Fields"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:241 src/Module/Welcome.php:58 #: src/Module/Settings/Profile/Index.php:265 src/Module/Welcome.php:58
msgid "Upload Profile Photo" msgid "Upload Profile Photo"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:245 #: src/Module/Settings/Profile/Index.php:266
msgid "Display name:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:248
msgid "Street Address:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:249
msgid "Locality/City:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:250
msgid "Region/State:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:251
msgid "Postal/Zip Code:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:252
msgid "Country:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:254
msgid "XMPP (Jabber) address:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:254
msgid "The XMPP address will be published so that people can follow you there."
msgstr ""
#: src/Module/Settings/Profile/Index.php:255
msgid "Matrix (Element) address:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:255
msgid ""
"The Matrix address will be published so that people can follow you there."
msgstr ""
#: src/Module/Settings/Profile/Index.php:256
msgid "Homepage URL:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:257
msgid "Public Keywords:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:257
msgid "(Used for suggesting potential friends, can be seen by others)"
msgstr ""
#: src/Module/Settings/Profile/Index.php:258
msgid "Private Keywords:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:258
msgid "(Used for searching profiles, never shown to others)"
msgstr ""
#: src/Module/Settings/Profile/Index.php:259
#, php-format #, php-format
msgid "" msgid ""
"<p>Custom fields appear on <a href=\"%s\">your profile page</a>.</p>\n" "<p>Custom fields appear on <a href=\"%s\">your profile page</a>.</p>\n"
@ -10276,6 +10220,63 @@ msgid ""
"contacts or the Friendica contacts in the selected circles.</p>" "contacts or the Friendica contacts in the selected circles.</p>"
msgstr "" msgstr ""
#: src/Module/Settings/Profile/Index.php:286
msgid "Street Address:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:287
msgid "Locality/City:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:288
msgid "Region/State:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:289
msgid "Postal/Zip Code:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:290
msgid "Country:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:292
msgid "XMPP (Jabber) address:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:292
msgid "The XMPP address will be published so that people can follow you there."
msgstr ""
#: src/Module/Settings/Profile/Index.php:293
msgid "Matrix (Element) address:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:293
msgid ""
"The Matrix address will be published so that people can follow you there."
msgstr ""
#: src/Module/Settings/Profile/Index.php:294
msgid "Homepage URL:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:295
msgid "Public Keywords:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:295
msgid "(Used for suggesting potential friends, can be seen by others)"
msgstr ""
#: src/Module/Settings/Profile/Index.php:296
msgid "Private Keywords:"
msgstr ""
#: src/Module/Settings/Profile/Index.php:296
msgid "(Used for searching profiles, never shown to others)"
msgstr ""
#: src/Module/Settings/Profile/Photo/Crop.php:107 #: src/Module/Settings/Profile/Photo/Crop.php:107
#: src/Module/Settings/Profile/Photo/Crop.php:125 #: src/Module/Settings/Profile/Photo/Crop.php:125
#: src/Module/Settings/Profile/Photo/Crop.php:143 #: src/Module/Settings/Profile/Photo/Crop.php:143

View file

@ -1,121 +1,131 @@
<h1>{{$banner}}</h1> <script>
$(document).ready(function () {
//$('.toggle-section-content + .toggle-section-content').hide();
$('.js-section-toggler').click(function () {
$('.toggle-section-content').hide();
$(this).parents('.toggle-section').find('.toggle-section-content').toggle();
});
});
</script>
{{$default nofilter}} <h1>{{$l10n.banner}}</h1>
<div id="profile-edit-links"> <div id="profile-edit-links">
<ul> <ul>
<li><a href="settings/profile/photo" id="profile-photo_upload-link" title="{{$profpic}}">{{$profpic}}</a></li> <li><a class="btn" href="profile/{{$nickname}}/profile" id="profile-edit-view-link">{{$l10n.viewprof}}</a></li>
<li><a href="profile/{{$nickname}}/profile" id="profile-edit-view-link" title="{{$viewprof}}">{{$viewprof}}</a></li>
</ul> </ul>
</div> </div>
<div id="profile-edit-links-end"></div> <div id="profile-edit-links-end"></div>
<div id="profile-edit-wrapper"> <div id="profile-edit-wrapper">
<form id="profile-edit-form" name="form1" action="settings/profiles" method="post"> <form enctype="multipart/form-data" action="settings/profile/photo" method="post">
<input type="hidden" name="form_security_token" value="{{$form_security_token_photo}}">
<!-- Profile picture -->
<div class="toggle-section js-toggle-section">
<h2><a class="section-caption js-section-toggler" href="javascript:;">{{$l10n.picture_section}} &raquo;</a></h2>
<div class="js-section toggle-section-content hidden">
<div id="profile-photo-upload-wrapper">
<label id="profile-photo-upload-label" for="profile-photo-upload">{{$l10n.profile_photo}}:</label>
<input name="userfile" type="file" id="profile-photo-upload" size="48"/>
</div>
<div class="profile-edit-submit-wrapper">
<button type="submit" name="submit" class="profile-edit-submit-button">{{$l10n.submit}}</button>
</div>
<div class="profile-edit-submit-end"></div>
</div>
</div>
</form>
<form id="profile-edit-form" name="form1" action="" method="post">
<input type="hidden" name="form_security_token" value="{{$form_security_token}}"> <input type="hidden" name="form_security_token" value="{{$form_security_token}}">
<div id="profile-edit-name-wrapper"> <!-- Basic information -->
<label id="profile-edit-name-label" for="profile-edit-name">{{$name.1}} </label> <div class="toggle-section js-toggle-section">
<input type="text" size="32" name="name" id="profile-edit-name" value="{{$name.2}}"/> <h2><a class="section-caption js-section-toggler" href="javascript:;">{{$l10n.personal_section}} &raquo;</a></h2>
</div> <div class="js-section toggle-section-content hidden">
<div id="profile-edit-name-end"></div>
<div id="profile-edit-about-wrapper">
<label id="profile-edit-about-label" for="profile-edit-about">{{$about.1}} </label>
<input type="text" size="32" name="about" id="profile-edit-about" value="{{$about.1}}"/>
</div>
<div id="profile-edit-about-end"></div>
<div id="profile-edit-dob-wrapper">
{{$dob nofilter}}
</div>
<div id="profile-edit-dob-end"></div>
{{$hide_friends nofilter}}
<div class="profile-edit-submit-wrapper">
<input type="submit" name="submit" class="profile-edit-submit-button" value="{{$submit}}"/>
</div>
<div class="profile-edit-submit-end"></div>
<div id="profile-edit-address-wrapper">
<label id="profile-edit-address-label" for="profile-edit-address">{{$address.1}} </label>
<input type="text" size="32" name="address" id="profile-edit-address" value="{{$address.2}}"/>
</div>
<div id="profile-edit-address-end"></div>
<div id="profile-edit-locality-wrapper">
<label id="profile-edit-locality-label" for="profile-edit-locality">{{$locality.1}} </label>
<input type="text" size="32" name="locality" id="profile-edit-locality" value="{{$locality.2}}"/>
</div>
<div id="profile-edit-locality-end"></div>
<div id="profile-edit-postal-code-wrapper">
<label id="profile-edit-postal-code-label" for="profile-edit-postal-code">{{$postal_code.1}} </label>
<input type="text" size="32" name="postal_code" id="profile-edit-postal-code" value="{{$postal_code.2}}"/>
</div>
<div id="profile-edit-postal-code-end"></div>
<div id="profile-edit-country-name-wrapper">
<label id="profile-edit-country-name-label" for="profile-edit-country-name">{{$country_name.1}} </label>
<select name="country_name" id="profile-edit-country-name" onChange="Fill_States('{{$region.2}}');">
<option selected="selected">{{$country_name.2}}</option>
<option>temp</option>
</select>
</div>
<div id="profile-edit-country-name-end"></div>
<div id="profile-edit-region-wrapper">
<label id="profile-edit-region-label" for="profile-edit-region">{{$region.1}} </label>
<select name="region" id="profile-edit-region" onChange="Update_Globals();">
<option selected="selected">{{$region.2}}</option>
<option>temp</option>
</select>
</div>
<div id="profile-edit-region-end"></div>
<div class="profile-edit-submit-wrapper">
<input type="submit" name="submit" class="profile-edit-submit-button" value="{{$submit}}"/>
</div>
<div class="profile-edit-submit-end"></div>
<div id="profile-edit-homepage-wrapper">
<label id="profile-edit-homepage-label" for="profile-edit-homepage">{{$homepage.1}} </label>
<input type="url" size="32" name="homepage" id="profile-edit-homepage" value="{{$homepage.2}}"/>
</div>
<div id="profile-edit-homepage-desc">{{$homepage.3}}</div>
<div id="profile-edit-homepage-end"></div>
<div id="profile-edit-xmpp-wrapper">
<label id="profile-edit-xmpp-label" for="profile-edit-xmpp">{{$xmpp.1}} </label>
<input type="text" size="32" name="xmpp" id="profile-edit-xmpp" title="{{$lbl_ex2}}" value="{{$xmpp.2}}"/>
</div>
<div id="profile-edit-xmpp-desc">{{$xmpp.3}}</div>
<div id="profile-edit-xmpp-end"></div>
<div id="profile-edit-matrix-wrapper">
<label id="profile-edit-matrix-label" for="profile-edit-matrix">{{$matrix.1}} </label>
<input type="text" size="32" name="matrix" id="profile-edit-matrix" title="{{$lbl_ex2}}" value="{{$matrix.2}}"/>
</div>
<div id="profile-edit-matrix-desc">{{$matrix.3}}</div>
<div id="profile-edit-matrix-end"></div>
<div id="profile-edit-pubkeywords-wrapper">
<label id="profile-edit-pubkeywords-label" for="profile-edit-pubkeywords">{{$pub_keywords.1}} </label>
<input type="text" size="32" name="pub_keywords" id="profile-edit-pubkeywords" title="{{$lbl_ex2}}" value="{{$pub_keywords.2}}"/>
</div>
<div id="profile-edit-pubkeywords-desc">{{$pub_keywords.3}}</div>
<div id="profile-edit-pubkeywords-end"></div>
<div id="profile-edit-prvkeywords-wrapper">
<label id="profile-edit-prvkeywords-label" for="profile-edit-prvkeywords">{{$prv_keywords.1}} </label>
<input type="text" size="32" name="prv_keywords" id="profile-edit-prvkeywords" title="{{$lbl_ex2}}" value="{{$prv_keywords.2}}"/>
</div>
<div id="profile-edit-prvkeywords-desc">{{$prv_keywords.3}}</div>
<div id="profile-edit-prvkeywords-end"></div>
<div class="profile-edit-submit-wrapper">
<input type="submit" name="submit" class="profile-edit-submit-button" value="{{$submit}}"/>
</div>
<div class="profile-edit-submit-end"></div>
<h2>{{$lbl_custom_fields_section}}</h2> {{include file="field_input.tpl" field=$username}}
{{$custom_fields_description nofilter}}
<div id="profile-custom-fields">
{{foreach $custom_fields as $custom_field}}
{{include file="settings/profile/field/edit.tpl" profile_field=$custom_field}}
{{/foreach}}
</div>
<div class="profile-edit-submit-wrapper"> {{include file="field_textarea.tpl" field=$about}}
<input type="submit" name="submit" class="profile-edit-submit-button" value="{{$submit}}"/>
{{include file="field_input.tpl" field=$xmpp}}
{{include file="field_input.tpl" field=$matrix}}
{{include file="field_input.tpl" field=$homepage}}
<div id="profile-edit-dob-wrapper">
{{$dob nofilter}}
</div>
<div id="profile-edit-dob-end"></div>
{{$hide_friends nofilter}}
{{include file="field_input.tpl" field=$pub_keywords}}
{{include file="field_input.tpl" field=$prv_keywords}}
<div class="profile-edit-submit-wrapper">
<button type="submit" name="submit" class="profile-edit-submit-button">{{$l10n.submit}}</button>
</div>
<div class="profile-edit-submit-end"></div>
</div>
</div>
<!-- About you -->
<div class="toggle-section js-toggle-section">
<h2><a class="section-caption js-section-toggler" href="javascript:;">{{$l10n.location_section}} &raquo;</a></h2>
<div class="js-section toggle-section-content hidden">
{{include file="field_input.tpl" field=$address}}
{{include file="field_input.tpl" field=$locality}}
{{include file="field_input.tpl" field=$postal_code}}
<div id="profile-edit-country-name-wrapper">
<label id="profile-edit-country-name-label" for="profile-edit-country-name">{{$country_name.1}} </label>
<select name="country_name" id="profile-edit-country-name" onChange="Fill_States('{{$region.2}}');">
<option selected="selected">{{$country_name.2}}</option>
</select>
</div>
<div id="profile-edit-country-name-end"></div>
<div id="profile-edit-region-wrapper">
<label id="profile-edit-region-label" for="profile-edit-region">{{$region.1}} </label>
<select name="region" id="profile-edit-region" onChange="Update_Globals();">
<option selected="selected">{{$region.2}}</option>
</select>
</div>
<div id="profile-edit-region-end"></div>
<div class="profile-edit-submit-wrapper">
<button type="submit" name="submit" class="profile-edit-submit-button">{{$l10n.submit}}</button>
</div>
<div class="profile-edit-submit-end"></div>
</div>
</div>
<!-- Interests -->
<div class="toggle-section js-toggle-section">
<h2><a class="section-caption js-section-toggler" href="javascript:;">{{$l10n.custom_fields_section}} &raquo;</a></h2>
<div class="js-section toggle-section-content hidden">
{{$custom_fields_description nofilter}}
<div id="profile-custom-fields">
{{foreach $custom_fields as $custom_field}}
{{include file="settings/profile/field/edit.tpl" profile_field=$custom_field}}
{{/foreach}}
</div>
<div class="profile-edit-submit-wrapper">
<button type="submit" name="submit" class="profile-edit-submit-button">{{$l10n.submit}}</button>
</div>
<div class="profile-edit-submit-end"></div>
</div>
</div> </div>
<div class="profile-edit-submit-end"></div>
</form> </form>
</div> </div>
<script type="text/javascript"> <script type="text/javascript">

View file

@ -1,18 +1,18 @@
<div class="generic-page-wrapper"> <div class="generic-page-wrapper">
<h1>{{$banner}}</h1> <h2>{{$l10n.banner}}</h2>
{{* The actions dropdown which can performed to the current profile *}} {{* The actions dropdown which can performed to the current profile *}}
<div id="profile-edit-links"> <div id="profile-edit-links">
<ul class="nav nav-pills preferences"> <ul class="nav nav-pills preferences">
<li class="dropdown pull-right"> <li class="dropdown pull-right">
<button type="button" class="btn btn-link dropdown-toggle" id="profile-edit-links-dropdown" data-toggle="dropdown" aria-expanded="false"> <button type="button" class="btn btn-link dropdown-toggle" id="profile-edit-links-dropdown" data-toggle="dropdown" aria-expanded="false">
<i class="fa fa-angle-down" aria-hidden="true"></i>&nbsp;{{$profile_action}} <i class="fa fa-angle-down" aria-hidden="true"></i>&nbsp;{{$l10n.profile_action}}
</button> </button>
<ul class="dropdown-menu pull-right" role="menu" aria-labelledby="profile-edit-links-dropdown"> <ul class="dropdown-menu pull-right" role="menu" aria-labelledby="profile-edit-links-dropdown">
<li role="presentation"><a role="menuitem" href="{{$profpiclink}}" id="profile-photo_upload-link" title="{{$profpic}}"><i class="fa fa-user" aria-hidden="true"></i>&nbsp;{{$profpic}}</a></li> <li role="presentation"><a role="menuitem" href="{{$profpiclink}}" id="profile-photo_upload-link"><i class="fa fa-user" aria-hidden="true"></i>&nbsp;{{$l10n.profpic}}</a></li>
<li role="presentation"><button role="menuitem" type="button" class="btn-link" id="profile-photo_upload-link-new" title="{{$lbl_profile_photo}}" onclick="openClose('profile-photo-upload-section');"><i class="fa fa-user" aria-hidden="true"></i>&nbsp;{{$lbl_profile_photo}}</button></li> <li role="presentation"><button role="menuitem" type="button" class="btn-link" id="profile-photo_upload-link-new" onclick="openClose('profile-photo-upload-section');"><i class="fa fa-user" aria-hidden="true"></i>&nbsp;{{$l10n.profile_photo}}</button></li>
<li role="presentation" class="divider"></li> <li role="presentation" class="divider"></li>
<li role="presentation"><a role="menuitem" href="profile/{{$nickname}}/profile" id="profile-edit-view-link" title="{{$viewprof}}">{{$viewprof}}</a></li> <li role="presentation"><a role="menuitem" href="profile/{{$nickname}}/profile" id="profile-edit-view-link">{{$l10n.viewprof}}</a></li>
</ul> </ul>
</li> </li>
</ul> </ul>
@ -26,12 +26,12 @@
<div id="profile-photo-upload-section" class="panel"> <div id="profile-photo-upload-section" class="panel">
<a id="profile-photo-upload-close" class="close pull-right" onclick="openClose('profile-photo-upload-section');"><i class="fa fa-times" aria-hidden="true"></i></a> <a id="profile-photo-upload-close" class="close pull-right" onclick="openClose('profile-photo-upload-section');"><i class="fa fa-times" aria-hidden="true"></i></a>
<div id="profile-photo-upload-wrapper"> <div id="profile-photo-upload-wrapper">
<label id="profile-photo-upload-label" for="profile-photo-upload">{{$lbl_profile_photo}}:</label> <label id="profile-photo-upload-label" for="profile-photo-upload">{{$l10n.profile_photo}}:</label>
<input name="userfile" type="file" id="profile-photo-upload" size="48" /> <input name="userfile" type="file" id="profile-photo-upload" size="48" />
</div> </div>
<div class="profile-edit-submit-wrapper pull-right"> <div class="profile-edit-submit-wrapper pull-right">
<button type="submit" name="submit" class="profile-edit-submit-button btn btn-primary" value="{{$submit}}">{{$submit}}</button> <button type="submit" name="submit" class="profile-edit-submit-button btn btn-primary">{{$l10n.submit}}</button>
</div> </div>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
@ -53,14 +53,14 @@
<div class="section-subtitle-wrapper panel-heading" role="tab" id="personal"> <div class="section-subtitle-wrapper panel-heading" role="tab" id="personal">
<h2> <h2>
<button class="btn-link accordion-toggle" data-toggle="collapse" data-parent="#profile-edit-wrapper" href="#personal-collapse" aria-expanded="true" aria-controls="personal-collapse"> <button class="btn-link accordion-toggle" data-toggle="collapse" data-parent="#profile-edit-wrapper" href="#personal-collapse" aria-expanded="true" aria-controls="personal-collapse">
{{$lbl_personal_section}} {{$l10n.personal_section}}
</button> </button>
</h2> </h2>
</div> </div>
{{* for the $detailed_profile we use bootstraps collapsable panel-groups to have expandable groups *}} {{* for the $detailed_profile we use bootstraps collapsable panel-groups to have expandable groups *}}
<div id="personal-collapse" class="panel-collapse collapse in" role="tabpanel" aria-labelledby="personal"> <div id="personal-collapse" class="panel-collapse collapse in" role="tabpanel" aria-labelledby="personal">
<div class="panel-body"> <div class="panel-body">
{{include file="field_input.tpl" field=$name}} {{include file="field_input.tpl" field=$username}}
{{include file="field_textarea.tpl" field=$about}} {{include file="field_textarea.tpl" field=$about}}
@ -69,7 +69,7 @@
{{$hide_friends nofilter}} {{$hide_friends nofilter}}
</div> </div>
<div class="panel-footer"> <div class="panel-footer">
<button type="submit" name="submit" class="btn btn-primary" value="{{$submit}}">{{$submit}}</button> <button type="submit" name="submit" class="btn btn-primary">{{$l10n.submit}}</button>
</div> </div>
</div> </div>
</div> </div>
@ -79,7 +79,7 @@
<div class="section-subtitle-wrapper panel-heading" role="tab" id="location"> <div class="section-subtitle-wrapper panel-heading" role="tab" id="location">
<h2> <h2>
<button class="btn-link accordion-toggle collapsed" data-toggle="collapse" data-parent="#profile-edit-wrapper" href="#location-collapse" aria-expanded="false" aria-controls="location-collapse"> <button class="btn-link accordion-toggle collapsed" data-toggle="collapse" data-parent="#profile-edit-wrapper" href="#location-collapse" aria-expanded="false" aria-controls="location-collapse">
{{$lbl_location_section}} {{$l10n.location_section}}
</button> </button>
</h2> </h2>
</div> </div>
@ -109,7 +109,7 @@
</div> </div>
</div> </div>
<div class="panel-footer"> <div class="panel-footer">
<button type="submit" name="submit" class="btn btn-primary" value="{{$submit}}">{{$submit}}</button> <button type="submit" name="submit" class="btn btn-primary">{{$l10n.submit}}</button>
</div> </div>
</div> </div>
</div> </div>
@ -119,7 +119,7 @@
<div class="section-subtitle-wrapper panel-heading" role="tab" id="miscellaneous"> <div class="section-subtitle-wrapper panel-heading" role="tab" id="miscellaneous">
<h2> <h2>
<button class="btn-link accordion-toggle collapsed" data-toggle="collapse" data-parent="#profile-edit-wrapper" href="#miscellaneous-collapse" aria-expanded="false" aria-controls="miscellaneous-collapse"> <button class="btn-link accordion-toggle collapsed" data-toggle="collapse" data-parent="#profile-edit-wrapper" href="#miscellaneous-collapse" aria-expanded="false" aria-controls="miscellaneous-collapse">
{{$lbl_miscellaneous_section}} {{$l10n.miscellaneous_section}}
</button> </button>
</h2> </h2>
</div> </div>
@ -136,7 +136,7 @@
{{include file="field_input.tpl" field=$prv_keywords}} {{include file="field_input.tpl" field=$prv_keywords}}
</div> </div>
<div class="panel-footer"> <div class="panel-footer">
<button type="submit" name="submit" class="btn btn-primary" value="{{$submit}}">{{$submit}}</button> <button type="submit" name="submit" class="btn btn-primary">{{$l10n.submit}}</button>
</div> </div>
</div> </div>
</div> </div>
@ -146,7 +146,7 @@
<div class="section-subtitle-wrapper panel-heading" role="tab" id="custom-fields"> <div class="section-subtitle-wrapper panel-heading" role="tab" id="custom-fields">
<h2> <h2>
<button class="btn-link accordion-toggle collapsed" data-toggle="collapse" data-parent="#profile-edit-wrapper" href="#custom-fields-collapse" aria-expanded="false" aria-controls="custom-fields-collapse"> <button class="btn-link accordion-toggle collapsed" data-toggle="collapse" data-parent="#profile-edit-wrapper" href="#custom-fields-collapse" aria-expanded="false" aria-controls="custom-fields-collapse">
{{$lbl_custom_fields_section}} {{$l10n.custom_fields_section}}
</button> </button>
</h2> </h2>
</div> </div>
@ -160,7 +160,7 @@
</div> </div>
</div> </div>
<div class="panel-footer"> <div class="panel-footer">
<button type="submit" name="submit" class="btn btn-primary" value="{{$submit}}">{{$submit}}</button> <button type="submit" name="submit" class="btn btn-primary">{{$l10n.submit}}</button>
</div> </div>
</div> </div>
</div> </div>

View file

@ -1,179 +0,0 @@
<script>
$(document).ready(function () {
//$('.toggle-section-content + .toggle-section-content').hide();
$('.js-section-toggler').click(function () {
$('.toggle-section-content').hide();
$(this).parents('.toggle-section').find('.toggle-section-content').toggle();
});
});
</script>
<h1>{{$banner}}</h1>
<div id="profile-edit-links">
<ul>
<li><a class="btn" href="profile/{{$nickname}}/profile" id="profile-edit-view-link" title="{{$viewprof}}">{{$viewprof}}</a></li>
</ul>
</div>
<div id="profile-edit-links-end"></div>
<div id="profile-edit-wrapper">
<form enctype="multipart/form-data" action="settings/profile/photo" method="post">
<input type="hidden" name="form_security_token" value="{{$form_security_token_photo}}">
<!-- Profile picture -->
<div class="toggle-section js-toggle-section">
<h2><a class="section-caption js-section-toggler" href="javascript:;">{{$lbl_picture_section}} &raquo;</a></h2>
<div class="js-section toggle-section-content hidden">
<div id="profile-photo-upload-wrapper">
<label id="profile-photo-upload-label" for="profile-photo-upload">{{$lbl_profile_photo}}:</label>
<input name="userfile" type="file" id="profile-photo-upload" size="48"/>
</div>
<div class="profile-edit-submit-wrapper">
<input type="submit" name="submit" class="profile-edit-submit-button" value="{{$submit}}"/>
</div>
<div class="profile-edit-submit-end"></div>
</div>
</div>
</form>
<form id="profile-edit-form" name="form1" action="" method="post">
<input type="hidden" name="form_security_token" value="{{$form_security_token}}">
<!-- Basic information -->
<div class="toggle-section js-toggle-section">
<h2><a class="section-caption js-section-toggler" href="javascript:;">{{$lbl_personal_section}} &raquo;</a></h2>
<div class="js-section toggle-section-content hidden">
<div id="profile-edit-name-wrapper">
<label id="profile-edit-name-label" for="profile-edit-name">{{$name.1}} </label>
<input type="text" size="32" name="name" id="profile-edit-name" value="{{$name.2}}"/>
</div>
<div id="profile-edit-name-end"></div>
<div id="profile-edit-about-wrapper">
<label id="profile-edit-about-label" for="profile-edit-about">{{$about.1}} </label>
<input type="text" size="32" name="about" id="profile-edit-about" value="{{$about.2}}"/>
</div>
<div id="profile-edit-about-end"></div>
<div id="profile-edit-xmpp-wrapper">
<label id="profile-edit-xmpp-label" for="profile-edit-xmpp">{{$xmpp.1}} </label>
<input type="text" size="32" name="xmpp" id="profile-edit-xmpp" value="{{$xmpp.2}}"/>
</div>
<div id="profile-edit-xmpp-desc">{{$xmpp.3}}</div>
<div id="profile-edit-xmpp-end"></div>
<div id="profile-edit-matrix-wrapper">
<label id="profile-edit-matrix-label" for="profile-edit-matrix">{{$matrix.1}} </label>
<input type="text" size="32" name="matrix" id="profile-edit-matrix" value="{{$matrix.2}}"/>
</div>
<div id="profile-edit-matrix-desc">{{$matrix.3}}</div>
<div id="profile-edit-matrix-end"></div>
<div id="profile-edit-homepage-wrapper">
<label id="profile-edit-homepage-label" for="profile-edit-homepage">{{$homepage.1}} </label>
<input type="text" size="32" name="homepage" id="profile-edit-homepage" value="{{$homepage.2}}"/>
</div>
<div id="profile-edit-homepage-desc">{{$homepage.3}}</div>
<div id="profile-edit-homepage-end"></div>
<div id="profile-edit-dob-wrapper">
{{$dob nofilter}}
</div>
<div id="profile-edit-dob-end"></div>
{{$hide_friends nofilter}}
<div id="profile-edit-pubkeywords-wrapper">
<label id="profile-edit-pubkeywords-label" for="profile-edit-pubkeywords">{{$pub_keywords.1}} </label>
<input type="text" size="32" name="pub_keywords" id="profile-edit-pubkeywords" title="{{$lbl_ex2}}" value="{{$pub_keywords.2}}"/>
</div>
<div id="profile-edit-pubkeywords-desc">{{$pub_keywords.3}}</div>
<div id="profile-edit-pubkeywords-end"></div>
<div id="profile-edit-prvkeywords-wrapper">
<label id="profile-edit-prvkeywords-label" for="profile-edit-prvkeywords">{{$prv_keywords.1}} </label>
<input type="text" size="32" name="prv_keywords" id="profile-edit-prvkeywords" title="{{$lbl_ex2}}" value="{{$prv_keywords.2}}"/>
</div>
<div id="profile-edit-prvkeywords-desc">{{$prv_keywords.3}}</div>
<div id="profile-edit-prvkeywords-end"></div>
<div class="profile-edit-submit-wrapper">
<input type="submit" name="submit" class="profile-edit-submit-button" value="{{$submit}}"/>
</div>
<div class="profile-edit-submit-end"></div>
</div>
</div>
<!-- About you -->
<div class="toggle-section js-toggle-section">
<h2><a class="section-caption js-section-toggler" href="javascript:;">{{$lbl_location_section}} &raquo;</a></h2>
<div class="js-section toggle-section-content hidden">
<div id="profile-edit-address-wrapper">
<label id="profile-edit-address-label" for="profile-edit-address">{{$address.1}} </label>
<input type="text" size="32" name="address" id="profile-edit-address" value="{{$address.2}}"/>
</div>
<div id="profile-edit-address-end"></div>
<div id="profile-edit-locality-wrapper">
<label id="profile-edit-locality-label" for="profile-edit-locality">{{$locality.1}} </label>
<input type="text" size="32" name="locality" id="profile-edit-locality" value="{{$locality.2}}"/>
</div>
<div id="profile-edit-locality-end"></div>
<div id="profile-edit-postal-code-wrapper">
<label id="profile-edit-postal-code-label" for="profile-edit-postal-code">{{$postal_code.1}} </label>
<input type="text" size="32" name="postal_code" id="profile-edit-postal-code" value="{{$postal_code.2}}"/>
</div>
<div id="profile-edit-postal-code-end"></div>
<div id="profile-edit-country-name-wrapper">
<label id="profile-edit-country-name-label" for="profile-edit-country-name">{{$country_name.1}} </label>
<select name="country_name" id="profile-edit-country-name" onChange="Fill_States('{{$region.2}}');">
<option selected="selected">{{$country_name.2}}</option>
</select>
</div>
<div id="profile-edit-country-name-end"></div>
<div id="profile-edit-region-wrapper">
<label id="profile-edit-region-label" for="profile-edit-region">{{$region.1}} </label>
<select name="region" id="profile-edit-region" onChange="Update_Globals();">
<option selected="selected">{{$region.2}}</option>
</select>
</div>
<div id="profile-edit-region-end"></div>
<div class="profile-edit-submit-wrapper">
<input type="submit" name="submit" class="profile-edit-submit-button" value="{{$submit}}"/>
</div>
<div class="profile-edit-submit-end"></div>
</div>
</div>
<!-- Interests -->
<div class="toggle-section js-toggle-section">
<h2><a class="section-caption js-section-toggler" href="javascript:;">{{$lbl_custom_fields_section}} &raquo;</a></h2>
<div class="js-section toggle-section-content hidden">
{{$custom_fields_description nofilter}}
<div id="profile-custom-fields">
{{foreach $custom_fields as $custom_field}}
{{include file="settings/profile/field/edit.tpl" profile_field=$custom_field}}
{{/foreach}}
</div>
<div class="profile-edit-submit-wrapper">
<input type="submit" name="submit" class="profile-edit-submit-button" value="{{$submit}}"/>
</div>
<div class="profile-edit-submit-end"></div>
</div>
</div>
</form>
</div>
<script type="text/javascript">
Fill_Country('{{$country_name.2}}');
Fill_States('{{$region.2}}');
</script>