The XMPP address is now in the profile and will be transmitted

This commit is contained in:
Michael Vogel 2016-09-25 15:28:00 +00:00
parent 4caaeb9978
commit 196eb6009f
25 changed files with 176 additions and 24 deletions

View File

@ -38,7 +38,7 @@ define ( 'FRIENDICA_PLATFORM', 'Friendica');
define ( 'FRIENDICA_CODENAME', 'Asparagus'); define ( 'FRIENDICA_CODENAME', 'Asparagus');
define ( 'FRIENDICA_VERSION', '3.5.1-dev' ); define ( 'FRIENDICA_VERSION', '3.5.1-dev' );
define ( 'DFRN_PROTOCOL_VERSION', '2.23' ); define ( 'DFRN_PROTOCOL_VERSION', '2.23' );
define ( 'DB_UPDATE_VERSION', 1202 ); define ( 'DB_UPDATE_VERSION', 1203 );
/** /**
* @brief Constant with a HTML line break. * @brief Constant with a HTML line break.
@ -181,6 +181,16 @@ define ( 'PAGE_BLOG', 4 );
define ( 'PAGE_PRVGROUP', 5 ); define ( 'PAGE_PRVGROUP', 5 );
/** @}*/ /** @}*/
/**
* @name page types
*
* @{
*/
define ( 'PAGE_TYPE_PERSON', 0 );
define ( 'PAGE_TYPE_COMPANY', 1 );
define ( 'PAGE_TYPE_COMMUNITY', 2 );
/** @}*/
/** /**
* @name CP * @name CP
* *

View File

@ -1,6 +1,6 @@
-- ------------------------------------------ -- ------------------------------------------
-- Friendica 3.5-dev (Asparagus) -- Friendica 3.5.1-dev (Asparagus)
-- DB_UPDATE_VERSION 1200 -- DB_UPDATE_VERSION 1202
-- ------------------------------------------ -- ------------------------------------------
@ -118,6 +118,7 @@ CREATE TABLE IF NOT EXISTS `contact` (
`about` text, `about` text,
`keywords` text, `keywords` text,
`gender` varchar(32) NOT NULL DEFAULT '', `gender` varchar(32) NOT NULL DEFAULT '',
`xmpp` varchar(255) NOT NULL DEFAULT '',
`attag` varchar(255) NOT NULL DEFAULT '', `attag` varchar(255) NOT NULL DEFAULT '',
`avatar` varchar(255) NOT NULL DEFAULT '', `avatar` varchar(255) NOT NULL DEFAULT '',
`photo` text, `photo` text,
@ -771,6 +772,17 @@ CREATE TABLE IF NOT EXISTS `poll_result` (
INDEX `choice` (`choice`) INDEX `choice` (`choice`)
) DEFAULT CHARSET=utf8mb4; ) DEFAULT CHARSET=utf8mb4;
--
-- TABLE process
--
CREATE TABLE IF NOT EXISTS `process` (
`pid` int(10) unsigned NOT NULL,
`command` varchar(32) NOT NULL DEFAULT '',
`created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
PRIMARY KEY(`pid`),
INDEX `command` (`command`)
) DEFAULT CHARSET=utf8mb4;
-- --
-- TABLE profile -- TABLE profile
-- --
@ -812,6 +824,7 @@ CREATE TABLE IF NOT EXISTS `profile` (
`education` text, `education` text,
`contact` text, `contact` text,
`homepage` varchar(255) NOT NULL DEFAULT '', `homepage` varchar(255) NOT NULL DEFAULT '',
`xmpp` varchar(255) NOT NULL DEFAULT '',
`photo` varchar(255) NOT NULL DEFAULT '', `photo` varchar(255) NOT NULL DEFAULT '',
`thumb` varchar(255) NOT NULL DEFAULT '', `thumb` varchar(255) NOT NULL DEFAULT '',
`publish` tinyint(1) NOT NULL DEFAULT 0, `publish` tinyint(1) NOT NULL DEFAULT 0,

View File

@ -209,21 +209,21 @@ function get_contact_details_by_url($url, $uid = -1, $default = array()) {
// Fetch contact data from the contact table for the given user // Fetch contact data from the contact table for the given user
$r = q("SELECT `id`, `id` AS `cid`, 0 AS `gid`, 0 AS `zid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, $r = q("SELECT `id`, `id` AS `cid`, 0 AS `gid`, 0 AS `zid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`,
`keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `bd` AS `birthday`, `self` `xmpp`, `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `bd` AS `birthday`, `self`
FROM `contact` WHERE `nurl` = '%s' AND `uid` = %d", FROM `contact` WHERE `nurl` = '%s' AND `uid` = %d",
dbesc(normalise_link($url)), intval($uid)); dbesc(normalise_link($url)), intval($uid));
// Fetch the data from the contact table with "uid=0" (which is filled automatically) // Fetch the data from the contact table with "uid=0" (which is filled automatically)
if (!$r) if (!$r)
$r = q("SELECT `id`, 0 AS `cid`, `id` AS `zid`, 0 AS `gid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, $r = q("SELECT `id`, 0 AS `cid`, `id` AS `zid`, 0 AS `gid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`,
`keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `bd` AS `birthday`, 0 AS `self` `xmpp`, `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `bd` AS `birthday`, 0 AS `self`
FROM `contact` WHERE `nurl` = '%s' AND `uid` = 0", FROM `contact` WHERE `nurl` = '%s' AND `uid` = 0",
dbesc(normalise_link($url))); dbesc(normalise_link($url)));
// Fetch the data from the gcontact table // Fetch the data from the gcontact table
if (!$r) if (!$r)
$r = q("SELECT 0 AS `id`, 0 AS `cid`, `id` AS `gid`, 0 AS `zid`, 0 AS `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, $r = q("SELECT 0 AS `id`, 0 AS `cid`, `id` AS `gid`, 0 AS `zid`, 0 AS `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`,
`keywords`, `gender`, `photo`, `photo` AS `thumb`, `photo` AS `micro`, `community` AS `forum`, 0 AS `prv`, `community`, `birthday`, 0 AS `self` '' AS `xmpp`, `keywords`, `gender`, `photo`, `photo` AS `thumb`, `photo` AS `micro`, `community` AS `forum`, 0 AS `prv`, `community`, `birthday`, 0 AS `self`
FROM `gcontact` WHERE `nurl` = '%s'", FROM `gcontact` WHERE `nurl` = '%s'",
dbesc(normalise_link($url))); dbesc(normalise_link($url)));

View File

@ -459,6 +459,7 @@ function db_definition() {
"about" => array("type" => "text"), "about" => array("type" => "text"),
"keywords" => array("type" => "text"), "keywords" => array("type" => "text"),
"gender" => array("type" => "varchar(32)", "not null" => "1", "default" => ""), "gender" => array("type" => "varchar(32)", "not null" => "1", "default" => ""),
"xmpp" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"attag" => array("type" => "varchar(255)", "not null" => "1", "default" => ""), "attag" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"avatar" => array("type" => "varchar(255)", "not null" => "1", "default" => ""), "avatar" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"photo" => array("type" => "text"), "photo" => array("type" => "text"),
@ -1164,6 +1165,7 @@ function db_definition() {
"education" => array("type" => "text"), "education" => array("type" => "text"),
"contact" => array("type" => "text"), "contact" => array("type" => "text"),
"homepage" => array("type" => "varchar(255)", "not null" => "1", "default" => ""), "homepage" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"xmpp" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"photo" => array("type" => "varchar(255)", "not null" => "1", "default" => ""), "photo" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"thumb" => array("type" => "varchar(255)", "not null" => "1", "default" => ""), "thumb" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"publish" => array("type" => "tinyint(1)", "not null" => "1", "default" => "0"), "publish" => array("type" => "tinyint(1)", "not null" => "1", "default" => "0"),

View File

@ -512,14 +512,16 @@ class dfrn {
xml::add_element($doc, $author, "dfrn:birthday", $birthday); xml::add_element($doc, $author, "dfrn:birthday", $birthday);
// Only show contact details when we are allowed to // Only show contact details when we are allowed to
$r = q("SELECT `profile`.`about`, `profile`.`name`, `profile`.`homepage`, `user`.`nickname`, `user`.`timezone`, $r = q("SELECT `profile`.`about`, `profile`.`name`, `profile`.`homepage`, `user`.`nickname`,
`profile`.`locality`, `profile`.`region`, `profile`.`country-name`, `profile`.`pub_keywords`, `profile`.`dob` `user`.`timezone`, `profile`.`locality`, `profile`.`region`, `profile`.`country-name`,
`profile`.`pub_keywords`, `profile`.`xmpp`, `profile`.`dob`
FROM `profile` FROM `profile`
INNER JOIN `user` ON `user`.`uid` = `profile`.`uid` INNER JOIN `user` ON `user`.`uid` = `profile`.`uid`
WHERE `profile`.`is-default` AND NOT `user`.`hidewall` AND `user`.`uid` = %d", WHERE `profile`.`is-default` AND NOT `user`.`hidewall` AND `user`.`uid` = %d",
intval($owner['uid'])); intval($owner['uid']));
if ($r) { if ($r) {
$profile = $r[0]; $profile = $r[0];
xml::add_element($doc, $author, "poco:displayName", $profile["name"]); xml::add_element($doc, $author, "poco:displayName", $profile["name"]);
xml::add_element($doc, $author, "poco:updated", $namdate); xml::add_element($doc, $author, "poco:updated", $namdate);
@ -550,12 +552,10 @@ class dfrn {
} }
/// @todo When we are having the XMPP address in the profile we should propagate it here if (trim($profile["xmpp"]) != "") {
$xmpp = "";
if (trim($xmpp) != "") {
$ims = $doc->createElement("poco:ims"); $ims = $doc->createElement("poco:ims");
xml::add_element($doc, $ims, "poco:type", "xmpp"); xml::add_element($doc, $ims, "poco:type", "xmpp");
xml::add_element($doc, $ims, "poco:value", $xmpp); xml::add_element($doc, $ims, "poco:value", $profile["xmpp"]);
xml::add_element($doc, $ims, "poco:primary", "true"); xml::add_element($doc, $ims, "poco:primary", "true");
$author->appendChild($ims); $author->appendChild($ims);
} }
@ -1143,7 +1143,7 @@ class dfrn {
$author["link"] = $xpath->evaluate($element."/atom:uri/text()", $context)->item(0)->nodeValue; $author["link"] = $xpath->evaluate($element."/atom:uri/text()", $context)->item(0)->nodeValue;
$r = q("SELECT `id`, `uid`, `url`, `network`, `avatar-date`, `name-date`, `uri-date`, `addr`, $r = q("SELECT `id`, `uid`, `url`, `network`, `avatar-date`, `name-date`, `uri-date`, `addr`,
`name`, `nick`, `about`, `location`, `keywords`, `bdyear`, `bd`, `hidden` `name`, `nick`, `about`, `location`, `keywords`, `xmpp`, `bdyear`, `bd`, `hidden`
FROM `contact` WHERE `uid` = %d AND `nurl` = '%s' AND `network` != '%s'", FROM `contact` WHERE `uid` = %d AND `nurl` = '%s' AND `network` != '%s'",
intval($importer["uid"]), dbesc(normalise_link($author["link"])), dbesc(NETWORK_STATUSNET)); intval($importer["uid"]), dbesc(normalise_link($author["link"])), dbesc(NETWORK_STATUSNET));
if ($r) { if ($r) {
@ -1219,9 +1219,13 @@ class dfrn {
if ($value != "") if ($value != "")
$poco["location"] = $value; $poco["location"] = $value;
/// @todo Only search for elements with "poco:type" = "xmpp"
$value = $xpath->evaluate($element."/poco:ims/poco:value/text()", $context)->item(0)->nodeValue;
if ($value != "")
$poco["xmpp"] = $value;
/// @todo Add support for the following fields that we don't support by now in the contact table: /// @todo Add support for the following fields that we don't support by now in the contact table:
/// - poco:utcOffset /// - poco:utcOffset
/// - poco:ims
/// - poco:urls /// - poco:urls
/// - poco:locality /// - poco:locality
/// - poco:region /// - poco:region
@ -1308,12 +1312,13 @@ class dfrn {
q("UPDATE `contact` SET `name` = '%s', `nick` = '%s', `about` = '%s', `location` = '%s', q("UPDATE `contact` SET `name` = '%s', `nick` = '%s', `about` = '%s', `location` = '%s',
`addr` = '%s', `keywords` = '%s', `bdyear` = '%s', `bd` = '%s', `hidden` = %d, `addr` = '%s', `keywords` = '%s', `bdyear` = '%s', `bd` = '%s', `hidden` = %d,
`name-date` = '%s', `uri-date` = '%s' `xmpp` = '%s', `name-date` = '%s', `uri-date` = '%s'
WHERE `id` = %d AND `network` = '%s'", WHERE `id` = %d AND `network` = '%s'",
dbesc($contact["name"]), dbesc($contact["nick"]), dbesc($contact["about"]), dbesc($contact["location"]), dbesc($contact["name"]), dbesc($contact["nick"]), dbesc($contact["about"]), dbesc($contact["location"]),
dbesc($contact["addr"]), dbesc($contact["keywords"]), dbesc($contact["bdyear"]), dbesc($contact["addr"]), dbesc($contact["keywords"]), dbesc($contact["bdyear"]),
dbesc($contact["bd"]), intval($contact["hidden"]), dbesc($contact["name-date"]), dbesc($contact["bd"]), intval($contact["hidden"]), dbesc($contact["xmpp"]),
dbesc($contact["uri-date"]), intval($contact["id"]), dbesc($contact["network"])); dbesc($contact["name-date"]), dbesc($contact["uri-date"]),
intval($contact["id"]), dbesc($contact["network"]));
} }
update_contact_avatar($author["avatar"], $importer["uid"], $contact["id"], update_contact_avatar($author["avatar"], $importer["uid"], $contact["id"],

View File

@ -337,6 +337,8 @@ function profile_sidebar($profile, $block = 0) {
$about = ((x($profile,'about') == 1) ? t('About:') : False); $about = ((x($profile,'about') == 1) ? t('About:') : False);
$xmpp = ((x($profile,'xmpp') == 1) ? t('XMPP:') : False);
if(($profile['hidewall'] || $block) && (! local_user()) && (! remote_user())) { if(($profile['hidewall'] || $block) && (! local_user()) && (! remote_user())) {
$location = $pdesc = $gender = $marital = $homepage = $about = False; $location = $pdesc = $gender = $marital = $homepage = $about = False;
} }
@ -405,6 +407,7 @@ function profile_sidebar($profile, $block = 0) {
$tpl = get_markup_template('profile_vcard.tpl'); $tpl = get_markup_template('profile_vcard.tpl');
$o .= replace_macros($tpl, array( $o .= replace_macros($tpl, array(
'$profile' => $p, '$profile' => $p,
'$xmpp' => $xmpp,
'$connect' => $connect, '$connect' => $connect,
'$remoteconnect' => $remoteconnect, '$remoteconnect' => $remoteconnect,
'$subscribe_feed' => $subscribe_feed, '$subscribe_feed' => $subscribe_feed,

View File

@ -626,6 +626,8 @@ function contacts_content(&$a) {
'account_type' => (($contact['forum'] || $contact['prv']) ? t('Forum') : ''), 'account_type' => (($contact['forum'] || $contact['prv']) ? t('Forum') : ''),
'$location' => bbcode($contact["location"]), '$location' => bbcode($contact["location"]),
'$location_label' => t("Location:"), '$location_label' => t("Location:"),
'$xmpp' => bbcode($contact["xmpp"]),
'$xmpp_label' => t("XMPP:"),
'$about' => bbcode($contact["about"], false, false), '$about' => bbcode($contact["about"], false, false),
'$about_label' => t("About:"), '$about_label' => t("About:"),
'$keywords' => $contact["keywords"], '$keywords' => $contact["keywords"],

View File

@ -303,6 +303,7 @@ function profiles_post(&$a) {
} }
$sexual = notags(trim($_POST['sexual'])); $sexual = notags(trim($_POST['sexual']));
$xmpp = notags(trim($_POST['xmpp']));
$homepage = notags(trim($_POST['homepage'])); $homepage = notags(trim($_POST['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
@ -368,6 +369,10 @@ function profiles_post(&$a) {
$changes[] = t('Sexual Preference'); $changes[] = t('Sexual Preference');
$value = $sexual; $value = $sexual;
} }
if($xmpp != $orig[0]['xmpp']) {
$changes[] = t('XMPP');
$value = $xmpp;
}
if($homepage != $orig[0]['homepage']) { if($homepage != $orig[0]['homepage']) {
$changes[] = t('Homepage'); $changes[] = t('Homepage');
$value = $homepage; $value = $homepage;
@ -409,6 +414,7 @@ function profiles_post(&$a) {
`with` = '%s', `with` = '%s',
`howlong` = '%s', `howlong` = '%s',
`sexual` = '%s', `sexual` = '%s',
`xmpp` = '%s',
`homepage` = '%s', `homepage` = '%s',
`hometown` = '%s', `hometown` = '%s',
`politic` = '%s', `politic` = '%s',
@ -443,6 +449,7 @@ function profiles_post(&$a) {
dbesc($with), dbesc($with),
dbesc($howlong), dbesc($howlong),
dbesc($sexual), dbesc($sexual),
dbesc($xmpp),
dbesc($homepage), dbesc($homepage),
dbesc($hometown), dbesc($hometown),
dbesc($politic), dbesc($politic),
@ -725,6 +732,7 @@ function profiles_content(&$a) {
'$howlong' => array('howlong', t('Since [date]:'), ($r[0]['howlong'] === '0000-00-00 00:00:00' ? '' : datetime_convert('UTC',date_default_timezone_get(),$r[0]['howlong']))), '$howlong' => array('howlong', t('Since [date]:'), ($r[0]['howlong'] === '0000-00-00 00:00:00' ? '' : datetime_convert('UTC',date_default_timezone_get(),$r[0]['howlong']))),
'$sexual' => sexpref_selector($r[0]['sexual']), '$sexual' => sexpref_selector($r[0]['sexual']),
'$about' => array('about', t('Tell us about yourself...'), $r[0]['about']), '$about' => array('about', t('Tell us about yourself...'), $r[0]['about']),
'$xmpp' => array('xmpp', t('XMPP (Jabber) address:'), $r[0]['xmpp'], t("The XMPP address will be propagated to your contacts so that they can follow you.")),
'$homepage' => array('homepage', t('Homepage URL:'), $r[0]['homepage']), '$homepage' => array('homepage', t('Homepage URL:'), $r[0]['homepage']),
'$hometown' => array('hometown', t('Hometown:'), $r[0]['hometown']), '$hometown' => array('hometown', t('Hometown:'), $r[0]['hometown']),
'$politic' => array('politic', t('Political Views:'), $r[0]['politic']), '$politic' => array('politic', t('Political Views:'), $r[0]['politic']),

View File

@ -1065,12 +1065,18 @@ function settings_content(&$a) {
if(! strlen($a->user['timezone'])) if(! strlen($a->user['timezone']))
$timezone = date_default_timezone_get(); $timezone = date_default_timezone_get();
$page_type = PAGE_TYPE_PERSON;
$pageset_tpl = get_markup_template('pagetypes.tpl'); $pageset_tpl = get_markup_template('pagetypes.tpl');
$pagetype = replace_macros($pageset_tpl, array( $pagetype = replace_macros($pageset_tpl, array(
'$user' => t("User Types"), '$user' => t("User Types"),
'$community' => t("Community Types"), '$company' => t("Company Types"),
'$community' => t("Community Types"),
'$page_type' => $page_type,
'$page_person' => PAGE_TYPE_PERSON,
'$page_company' => PAGE_TYPE_COMPANY,
'$page_forum' => PAGE_TYPE_COMMUNITY,
'$page_normal' => array('page-flags', t('Normal Account Page'), PAGE_NORMAL, '$page_normal' => array('page-flags', t('Normal Account Page'), PAGE_NORMAL,
t('This account is a normal personal profile'), t('This account is a normal personal profile'),
($a->user['page-flags'] == PAGE_NORMAL)), ($a->user['page-flags'] == PAGE_NORMAL)),

View File

@ -1,6 +1,6 @@
<?php <?php
define('UPDATE_VERSION' , 1202); define('UPDATE_VERSION' , 1203);
/** /**
* *

View File

@ -54,6 +54,7 @@
{{* Some information about the contact from the profile *}} {{* Some information about the contact from the profile *}}
<dl><dt>{{$profileurllabel}}</dt><dd><a target="blank" href="{{$url}}">{{$profileurl}}</a></dd></dl> <dl><dt>{{$profileurllabel}}</dt><dd><a target="blank" href="{{$url}}">{{$profileurl}}</a></dd></dl>
{{if $location}}<dl><dt>{{$location_label}}</dt><dd>{{$location}}</dd></dl>{{/if}} {{if $location}}<dl><dt>{{$location_label}}</dt><dd>{{$location}}</dd></dl>{{/if}}
{{if $xmpp}}<dl><dt>{{$xmpp_label}}</dt><dd>{{$xmpp}}</dd></dl>{{/if}}
{{if $keywords}}<dl><dt>{{$keywords_label}}</dt><dd>{{$keywords}}</dd></dl>{{/if}} {{if $keywords}}<dl><dt>{{$keywords_label}}</dt><dd>{{$keywords}}</dd></dl>{{/if}}
{{if $about}}<dl><dt>{{$about_label}}</dt><dd>{{$about}}</dd></dl>{{/if}} {{if $about}}<dl><dt>{{$about_label}}</dt><dd>{{$about}}</dd></dl>{{/if}}
</div>{{* End of contact-edit-links *}} </div>{{* End of contact-edit-links *}}

View File

@ -1,8 +1,15 @@
{{if $page_type == $page_person}}
<h4>{{$user}}</h4> <h4>{{$user}}</h4>
{{include file="field_radio.tpl" field=$page_normal}} {{include file="field_radio.tpl" field=$page_normal}}
{{include file="field_radio.tpl" field=$page_soapbox}} {{include file="field_radio.tpl" field=$page_soapbox}}
{{include file="field_radio.tpl" field=$page_freelove}} {{include file="field_radio.tpl" field=$page_freelove}}
{{/if}}
{{if $page_type == $page_company}}
<h4>{{$company}}</h4>
{{include file="field_radio.tpl" field=$page_soapbox}}
{{/if}}
{{if $page_type == $page_forum}}
<h4>{{$community}}</h4> <h4>{{$community}}</h4>
{{include file="field_radio.tpl" field=$page_community}} {{include file="field_radio.tpl" field=$page_community}}
{{include file="field_radio.tpl" field=$page_prvgroup}} {{include file="field_radio.tpl" field=$page_prvgroup}}
{{/if}}

View File

@ -134,6 +134,13 @@
</div> </div>
<div id="profile-edit-homepage-end"></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|escape:'html'}}" />
</div><div id="profile-edit-xmpp-desc">{{$xmpp.3}}</div>
<div id="profile-edit-xmpp-end"></div>
<div id="profile-edit-politic-wrapper" > <div id="profile-edit-politic-wrapper" >
<label id="profile-edit-politic-label" for="profile-edit-politic" >{{$politic.1}} </label> <label id="profile-edit-politic-label" for="profile-edit-politic" >{{$politic.1}} </label>
<input type="text" size="32" name="politic" id="profile-edit-politic" value="{{$politic.2|escape:'html'}}" /> <input type="text" size="32" name="politic" id="profile-edit-politic" value="{{$politic.2|escape:'html'}}" />
@ -352,6 +359,13 @@
</div> </div>
<div id="profile-edit-homepage-end"></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|escape:'html'}}" />
</div><div id="profile-edit-xmpp-desc">{{$xmpp.3}}</div>
<div id="profile-edit-xmpp-end"></div>
{{$hide_friends}} {{$hide_friends}}
<div id="profile-edit-address-wrapper" > <div id="profile-edit-address-wrapper" >

View File

@ -28,6 +28,13 @@
</dl> </dl>
{{/if}} {{/if}}
{{if $profile.xmpp}}
<dl class="xmpp">
<dt class="xmpp-label">{{$xmpp}}</dt>
<dd class="xmpp-data">{{$profile.xmpp}}</dd>
</dl>
{{/if}}
{{if $gender}}<dl class="mf"><dt class="gender-label">{{$gender}}</dt> <dd class="p-gender">{{$profile.gender}}</dd></dl>{{/if}} {{if $gender}}<dl class="mf"><dt class="gender-label">{{$gender}}</dt> <dd class="p-gender">{{$profile.gender}}</dd></dl>{{/if}}
{{if $profile.pubkey}}<div class="key u-key" style="display:none;">{{$profile.pubkey}}</div>{{/if}} {{if $profile.pubkey}}<div class="key u-key" style="display:none;">{{$profile.pubkey}}</div>{{/if}}

View File

@ -967,10 +967,14 @@ aside .vcard .p-addr {
white-space: nowrap; white-space: nowrap;
padding-bottom: 2px; padding-bottom: 2px;
} }
aside .vcard .detail { aside .vcard .detail {
display: table; display: table;
padding: 5px 0; padding: 5px 0;
} }
aside .xmpp {
display: table;
}
aside .vcard .icon { aside .vcard .icon {
display: table-cell; display: table-cell;
padding-right: 10px; padding-right: 10px;

View File

@ -88,6 +88,14 @@
</div> </div>
{{/if}} {{/if}}
{{if $xmpp}}
<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12">
<hr class="profile-separator">
<div class="col-lg-4 col-md-4 col-sm-4 col-xs-12 text-muted">{{$xmpp_label}}</div>
<div class="col-lg-8 col-md-8 col-sm-8 col-xs-12">{{$xmpp}}</div>
</div>
{{/if}}
{{if $keywords}} {{if $keywords}}
<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12"> <div class="col-lg-12 col-md-12 col-sm-12 col-xs-12">
<hr class="profile-separator"> <hr class="profile-separator">

View File

@ -203,6 +203,8 @@
<div class="section-content-tools-wrapper"> <div class="section-content-tools-wrapper">
{{include file="field_input.tpl" field=$homepage}} {{include file="field_input.tpl" field=$homepage}}
{{include file="field_input.tpl" field=$xmpp}}
{{include file="field_input.tpl" field=$pub_keywords}} {{include file="field_input.tpl" field=$pub_keywords}}
{{include file="field_input.tpl" field=$prv_keywords}} {{include file="field_input.tpl" field=$prv_keywords}}
@ -268,6 +270,8 @@
{{include file="field_input.tpl" field=$homepage}} {{include file="field_input.tpl" field=$homepage}}
{{include file="field_input.tpl" field=$xmpp}}
{{$hide_friends}} {{$hide_friends}}
{{include file="field_input.tpl" field=$address}} {{include file="field_input.tpl" field=$address}}

View File

@ -87,6 +87,12 @@
</div> </div>
{{/if}} {{/if}}
{{if $profile.xmpp}}
<div class="xmpp">
<span class="xmpp-label icon"><i class="fa fa-comments"></i></span>
<span class="xmpp-data">{{$profile.xmpp}}</span>
</div>
{{/if}}
{{if $gender}} {{if $gender}}
<div class="mf detail"> <div class="mf detail">

View File

@ -918,6 +918,7 @@ input#dfrn-url {
#profile-edit-religion-label, #profile-edit-religion-label,
#profile-edit-pubkeywords-label, #profile-edit-pubkeywords-label,
#profile-edit-prvkeywords-label, #profile-edit-prvkeywords-label,
#profile-edit-xmpp-label,
#profile-edit-homepage-label, #profile-edit-homepage-label,
#profile-edit-hometown-label { #profile-edit-hometown-label {
font-weight: 700; font-weight: 700;
@ -939,6 +940,7 @@ input#dfrn-url {
#sexual-select, #sexual-select,
#profile-edit-politic, #profile-edit-politic,
#profile-edit-religion, #profile-edit-religion,
#profile-edit-xmpp,
#profile-edit-pubkeywords, #profile-edit-pubkeywords,
#profile-edit-prvkeywords, #profile-edit-prvkeywords,
#profile-in-dir-yes, #profile-in-dir-yes,
@ -952,6 +954,7 @@ input#dfrn-url {
float: left; float: left;
margin-bottom: 20px; margin-bottom: 20px;
} }
#profile-edit-xmpp,
#profile-edit-pubkeywords, #profile-edit-pubkeywords,
#profile-edit-prvkeywords { #profile-edit-prvkeywords {
margin-bottom: 5px; margin-bottom: 5px;
@ -1024,6 +1027,7 @@ input#dfrn-url {
#profile-edit-pdesc-desc, #profile-edit-pdesc-desc,
#profile-edit-xmpp-desc,
#profile-edit-pubkeywords-desc, #profile-edit-pubkeywords-desc,
#profile-edit-prvkeywords-desc { #profile-edit-prvkeywords-desc {
float: left; float: left;
@ -1039,7 +1043,8 @@ input#dfrn-url {
float: left; float: left;
margin-bottom: 35px; margin-bottom: 35px;
}*/ }*/
#profile-edit-homepage, #profile-edit-hometown { #profile-edit-homepage,
#profile-edit-hometown {
float: left; float: left;
margin-bottom: 25px; margin-bottom: 25px;
} }
@ -1082,6 +1087,7 @@ input#dfrn-url {
#profile-edit-pubkeywords-end, #profile-edit-pubkeywords-end,
#profile-edit-prvkeywords-end, #profile-edit-prvkeywords-end,
#profile-edit-homepage-end, #profile-edit-homepage-end,
#profile-edit-xmpp-end,
#profile-edit-hometown-end, #profile-edit-hometown-end,
#profile-in-dir-break, #profile-in-dir-break,
#profile-in-dir-end, #profile-in-dir-end,
@ -1897,6 +1903,7 @@ input#dfrn-url {
#advanced-profile-marital-wrapper, #advanced-profile-marital-wrapper,
#advanced-profile-sexual-wrapper, #advanced-profile-sexual-wrapper,
#advanced-profile-homepage-wrapper, #advanced-profile-homepage-wrapper,
#advanced-profile-xmpp-wrapper,
#advanced-profile-politic-wrapper, #advanced-profile-politic-wrapper,
#advanced-profile-religion-wrapper, #advanced-profile-religion-wrapper,
#advanced-profile-about-wrapper, #advanced-profile-about-wrapper,
@ -1919,6 +1926,7 @@ input#dfrn-url {
#advanced-profile-marital-text, #advanced-profile-marital-text,
#advanced-profile-sexual-text, #advanced-profile-sexual-text,
#advanced-profile-homepage-text, #advanced-profile-homepage-text,
#advanced-profile-xmpp-text,
#advanced-profile-politic-text, #advanced-profile-politic-text,
#advanced-profile-religion-text, #advanced-profile-religion-text,
#advanced-profile-about-text, #advanced-profile-about-text,
@ -1942,6 +1950,7 @@ input#dfrn-url {
#advanced-profile-marital-end, #advanced-profile-marital-end,
#advanced-profile-sexual-end, #advanced-profile-sexual-end,
#advanced-profile-homepage-end, #advanced-profile-homepage-end,
#advanced-profile-xmpp-end,
#advanced-profile-politic-end, #advanced-profile-politic-end,
#advanced-profile-religion-end { #advanced-profile-religion-end {
height: 10px; height: 10px;
@ -1968,6 +1977,7 @@ input#dfrn-url {
#advanced-profile-marital, #advanced-profile-marital,
#advanced-profile-sexual, #advanced-profile-sexual,
#advanced-profile-homepage, #advanced-profile-homepage,
#advanced-profile-xmpp,
#advanced-profile-politic, #advanced-profile-politic,
#advanced-profile-religion { #advanced-profile-religion {
float: left; float: left;
@ -2912,14 +2922,14 @@ aside input[type='text'] {
margin-bottom: 25px; margin-bottom: 25px;
} }
.location-label, .gender-label, .marital-label, .homepage-label, .network-label { .location-label, .gender-label, .marital-label, .homepage-label, .ympp-label, .network-label, .xmpp-label {
float: left; float: left;
text-align: right; text-align: right;
display: block; display: block;
width: 65px; width: 65px;
} }
.adr, .x-gender, .marital-text, .homepage-url, .x-network { .adr, .x-gender, .marital-text, .homepage-url, .x-network, .xmpp-data {
float: left; float: left;
display: block; display: block;
margin-left: 8px; margin-left: 8px;

View File

@ -131,6 +131,12 @@
</div> </div>
<div id="profile-edit-homepage-end"></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="28" 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-politic-wrapper" > <div id="profile-edit-politic-wrapper" >
<label id="profile-edit-politic-label" for="profile-edit-politic" >{{$politic.1}} </label> <label id="profile-edit-politic-label" for="profile-edit-politic" >{{$politic.1}} </label>
<input type="text" size="28" name="politic" id="profile-edit-politic" value="{{$politic.2}}" /> <input type="text" size="28" name="politic" id="profile-edit-politic" value="{{$politic.2}}" />

View File

@ -26,6 +26,13 @@
</dl> </dl>
{{/if}} {{/if}}
{{if $profile.xmpp}}
<dl class="xmpp">
<dt class="xmpp-label">{{$xmpp}}</dt>
<dd class="xmpp-data">{{$profile.xmpp}}</dd>
</dl>
{{/if}}
{{if $gender}}<dl class="mf"><dt class="gender-label">{{$gender}}</dt> <dd class="p-gender">{{$profile.gender}}</dd></dl>{{/if}} {{if $gender}}<dl class="mf"><dt class="gender-label">{{$gender}}</dt> <dd class="p-gender">{{$profile.gender}}</dd></dl>{{/if}}
{{if $profile.pubkey}}<div class="key" style="display:none;">{{$profile.pubkey}}</div>{{/if}} {{if $profile.pubkey}}<div class="key" style="display:none;">{{$profile.pubkey}}</div>{{/if}}

View File

@ -49,6 +49,13 @@
</dl> </dl>
{{/if}} {{/if}}
{{if $profile.xmpp}}
<dl class="xmpp">
<dt class="xmpp-label">{{$xmpp}}</dt>
<dd class="xmpp-data">{{$profile.xmpp}}</dd>
</dl>
{{/if}}
{{if $gender}}<dl class="mf"><dt class="gender-label">{{$gender}}</dt> <dd class="p-gender">{{$profile.gender}}</dd></dl>{{/if}} {{if $gender}}<dl class="mf"><dt class="gender-label">{{$gender}}</dt> <dd class="p-gender">{{$profile.gender}}</dd></dl>{{/if}}
{{if $profile.pubkey}}<div class="key" style="display:none;">{{$profile.pubkey}}</div>{{/if}} {{if $profile.pubkey}}<div class="key" style="display:none;">{{$profile.pubkey}}</div>{{/if}}

View File

@ -54,6 +54,7 @@
{{* Some information about the contact from the profile *}} {{* Some information about the contact from the profile *}}
<dl><dt>{{$profileurllabel}}</dt><dd><a target="blank" href="{{$url}}">{{$profileurl}}</a></dd></dl> <dl><dt>{{$profileurllabel}}</dt><dd><a target="blank" href="{{$url}}">{{$profileurl}}</a></dd></dl>
{{if $location}}<dl><dt>{{$location_label}}</dt><dd>{{$location}}</dd></dl>{{/if}} {{if $location}}<dl><dt>{{$location_label}}</dt><dd>{{$location}}</dd></dl>{{/if}}
{{if $xmpp}}<dl><dt>{{$xmpp_label}}</dt><dd>{{$xmpp}}</dd></dl>{{/if}}
{{if $keywords}}<dl><dt>{{$keywords_label}}</dt><dd>{{$keywords}}</dd></dl>{{/if}} {{if $keywords}}<dl><dt>{{$keywords_label}}</dt><dd>{{$keywords}}</dd></dl>{{/if}}
{{if $about}}<dl><dt>{{$about_label}}</dt><dd>{{$about}}</dd></dl>{{/if}} {{if $about}}<dl><dt>{{$about_label}}</dt><dd>{{$about}}</dd></dl>{{/if}}
</div>{{* End of contact-edit-links *}} </div>{{* End of contact-edit-links *}}

View File

@ -93,6 +93,13 @@
</div> </div>
<div id="profile-edit-pdesc-end"></div> <div id="profile-edit-pdesc-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-homepage-wrapper" > <div id="profile-edit-homepage-wrapper" >
<label id="profile-edit-homepage-label" for="profile-edit-homepage" >{{$homepage.1}} </label> <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}}" /> <input type="text" size="32" name="homepage" id="profile-edit-homepage" value="{{$homepage.2}}" />
@ -342,6 +349,13 @@
<div id="profile-edit-dob-end"></div> <div id="profile-edit-dob-end"></div>
{{/if}} {{/if}}
<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-homepage-wrapper" > <div id="profile-edit-homepage-wrapper" >
<label id="profile-edit-homepage-label" for="profile-edit-homepage" >{{$homepage.1}} </label> <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}}" /> <input type="text" size="32" name="homepage" id="profile-edit-homepage" value="{{$homepage.2}}" />

View File

@ -39,6 +39,13 @@
</dl> </dl>
{{/if}} {{/if}}
{{if $profile.xmpp}}
<dl class="xmpp">
<dt class="xmpp-label">{{$xmpp}}</dt>
<dd class="xmpp-data">{{$profile.xmpp}}</dd>
</dl>
{{/if}}
{{if $gender}}<dl class="mf"><dt class="gender-label">{{$gender}}</dt> <dd class="p-gender">{{$profile.gender}}</dd></dl>{{/if}} {{if $gender}}<dl class="mf"><dt class="gender-label">{{$gender}}</dt> <dd class="p-gender">{{$profile.gender}}</dd></dl>{{/if}}
{{if $profile.pubkey}}<div class="key u-key" style="display:none;">{{$profile.pubkey}}</div>{{/if}} {{if $profile.pubkey}}<div class="key u-key" style="display:none;">{{$profile.pubkey}}</div>{{/if}}