$contact = DBA::selectFirst('contact', [], ['uid' => 0, 'nurl' => Strings::normaliseLink($url)]);
if (DBA::isResult($contact)) {
- $network_name = ContactSelector::networkToName($contact['network'], $contact['url']);
-
// If no nick where given, extract it from the address
if (($contact['nick'] == "") || ($contact['name'] == $contact['nick'])) {
$contact['nick'] = api_get_nick($contact["url"]);
'id_str' => (string) $contact["id"],
'name' => $contact["name"],
'screen_name' => (($contact['nick']) ? $contact['nick'] : $contact['name']),
- 'location' => ($contact["location"] != "") ? $contact["location"] : $network_name,
+ 'location' => ($contact["location"] != "") ? $contact["location"] : ContactSelector::networkToName($contact['network'], $contact['url']),
'description' => $contact["about"],
'profile_image_url' => $contact["micro"],
'profile_image_url_https' => $contact["micro"],
$uinfo[0]['nick'] = api_get_nick($uinfo[0]["url"]);
}
- $network_name = ContactSelector::networkToName($uinfo[0]['network'], $uinfo[0]['url']);
-
$pcontact_id = Contact::getIdForURL($uinfo[0]['url'], 0, true);
if (!empty($profile['about'])) {
} elseif (!empty($uinfo[0]["location"])) {
$location = $uinfo[0]["location"];
} else {
- $location = $network_name;
+ $location = ContactSelector::networkToName($uinfo[0]['network'], $uinfo[0]['url']);
}
$ret = [
* likes (etc.) can apply to other things besides posts. Check if they are post children,
* in which case we handle them specially
*/
- $hidden_activities = [ACTIVITY_LIKE, ACTIVITY_DISLIKE, ACTIVITY_ATTEND, ACTIVITY_ATTENDNO, ACTIVITY_ATTENDMAYBE];
+ $hidden_activities = [ACTIVITY_LIKE, ACTIVITY_DISLIKE, ACTIVITY_ATTEND, ACTIVITY_ATTENDNO, ACTIVITY_ATTENDMAYBE, ACTIVITY_FOLLOW];
foreach ($hidden_activities as $act) {
if (activity_match($item['verb'], $act)) {
return false;
$banner = '<a href="https://friendi.ca"><img id="logo-img" src="images/friendica-32.png" alt="logo" /></a><span id="logo-text"><a href="https://friendi.ca">Friendica</a></span>';
}
- $banner = htmlspecialchars($banner);
$info = Config::get('config', 'info');
- $info = htmlspecialchars($info);
// Automatically create temporary paths
get_temppath();
$entry = [
'url' => $rr['url'],
'itemurl' => defaults($contact_details, 'addr', $rr['url']),
- 'name' => htmlentities($contact_details['name']),
+ 'name' => $contact_details['name'],
'thumb' => ProxyUtils::proxifyUrl($contact_details['thumb'], false, ProxyUtils::SIZE_THUMB),
- 'img_hover' => htmlentities($contact_details['name']),
+ 'img_hover' => $contact_details['name'],
'details' => $contact_details['location'],
'tags' => $contact_details['keywords'],
'about' => $contact_details['about'],
$tab_str = Module\Contact::getTabsHTML($a, $contact, 4);
$tpl = Renderer::getMarkupTemplate('viewcontact_template.tpl');
-
$o .= Renderer::replaceMacros($tpl, [
- //'$title' => L10n::t('Friends of %s', htmlentities($c[0]['name'])),
'$tab_str' => $tab_str,
'$contacts' => $entries,
'$paginate' => $pager->renderFull($total),
$tpl = Renderer::getMarkupTemplate('babel.tpl');
$o = Renderer::replaceMacros($tpl, [
- '$text' => ['text', L10n::t('Source text'), htmlentities(defaults($_REQUEST, 'text', '')), ''],
+ '$text' => ['text', L10n::t('Source text'), defaults($_REQUEST, 'text', ''), ''],
'$type_bbcode' => ['type', L10n::t('BBCode'), 'bbcode', '', defaults($_REQUEST, 'type', 'bbcode') == 'bbcode'],
'$type_markdown' => ['type', L10n::t('Markdown'), 'markdown', '', defaults($_REQUEST, 'type', 'bbcode') == 'markdown'],
'$type_html' => ['type', L10n::t('HTML'), 'html', '', defaults($_REQUEST, 'type', 'bbcode') == 'html'],
if (DBA::isResult($contact)) {
$vcard_widget = Renderer::replaceMacros(Renderer::getMarkupTemplate("vcard-widget.tpl"), [
- '$name' => htmlentities($contact['name']),
+ '$name' => $contact['name'],
'$photo' => $contact['photo'],
'url' => 'contact/' . $cid
]);
'itemurl' => defaults($contact_details, 'addr', $common_friend['url']),
'name' => $contact_details['name'],
'thumb' => ProxyUtils::proxifyUrl($contact_details['thumb'], false, ProxyUtils::SIZE_THUMB),
- 'img_hover' => htmlentities($contact_details['name']),
+ 'img_hover' => $contact_details['name'],
'details' => $contact_details['location'],
'tags' => $contact_details['keywords'],
'about' => $contact_details['about'],
{
/* fill the page with credits */
$credits_string = file_get_contents('util/credits.txt');
- $names = explode("\n", htmlspecialchars($credits_string));
+ $names = explode("\n", $credits_string);
$tpl = Renderer::getMarkupTemplate('credits.tpl');
return Renderer::replaceMacros($tpl, [
'$title' => L10n::t('Credits'),
$remote_self_options
],
- '$name' => ['name', L10n::t('Name') , htmlentities($contact['name'])],
- '$nick' => ['nick', L10n::t('Account Nickname'), htmlentities($contact['nick'])],
+ '$name' => ['name', L10n::t('Name') , $contact['name']],
+ '$nick' => ['nick', L10n::t('Account Nickname'), $contact['nick']],
'$attag' => ['attag', L10n::t('@Tagname - overrides Name/Nickname'), $contact['attag']],
'$url' => ['url', L10n::t('Account URL'), $contact['url']],
'$request' => ['request', L10n::t('Friend Request URL'), $contact['request']],
switch ($direction) {
case -1:
if ($type === 'profile') {
- $sql_extra = sprintf(" AND ( `dfrn-id` = '%s' OR `issued-id` = '%s' ) ", DBA::escape($dfrn_id), DBA::escape($dfrn_id));
+ $sql_extra = sprintf(" AND (`dfrn-id` = '%s' OR `issued-id` = '%s') ", DBA::escape($dfrn_id), DBA::escape($dfrn_id));
} else {
$sql_extra = sprintf(" AND `issued-id` = '%s' ", DBA::escape($dfrn_id));
}
dfrn_request_post($a);
- killme();
- return; // NOTREACHED
+ exit();
}
$tpl = Renderer::getMarkupTemplate("dfrn_req_confirm.tpl");
'$dfrn_url' => $dfrn_url,
'$aes_allow' => (($aes_allow) ? '<input type="hidden" name="aes_allow" value="1" />' : "" ),
'$hidethem' => L10n::t('Hide this contact'),
- '$hidechecked' => '',
'$confirm_key' => $confirm_key,
'$welcome' => L10n::t('Welcome home %s.', $a->user['username']),
'$please' => L10n::t('Please confirm your introduction/connection request to %s.', $dfrn_url),
$parent = Item::selectFirst(['uid'], ['uri' => $item_parent_uri, 'wall' => true]);
if (DBA::isResult($parent)) {
- $a->profile['uid'] = $parent['uid'];
- $a->profile['profile_uid'] = $parent['uid'];
+ $a->profile['uid'] = defaults($a->profile, 'uid', $parent['uid']);
+ $a->profile['profile_uid'] = defaults($a->profile, 'profile_uid', $parent['uid']);
$is_remote_contact = Contact::isFollower(remote_user(), $a->profile['profile_uid']);
}
use Friendica\Content\Feature;
use Friendica\Core\Addon;
use Friendica\Core\Config;
+use Friendica\Core\Hook;
use Friendica\Core\L10n;
use Friendica\Core\Renderer;
use Friendica\Core\System;
'$nickname' => $a->user['nickname']
]);
- $tpl = Renderer::getMarkupTemplate("jot.tpl");
-
if (strlen($item['allow_cid']) || strlen($item['allow_gid']) || strlen($item['deny_cid']) || strlen($item['deny_gid'])) {
$lockstate = 'lock';
} else {
}
}
- Addon::callHooks('jot_tool', $jotplugins);
- //Addon::callHooks('jot_networks', $jotnets);
+ Hook::callAll('jot_tool', $jotplugins);
+ $tpl = Renderer::getMarkupTemplate("jot.tpl");
$o .= Renderer::replaceMacros($tpl, [
'$is_edit' => true,
'$return_path' => '/display/' . $item['guid'],
'$emailcc' => L10n::t('CC: email addresses'),
'$public' => L10n::t('Public post'),
'$jotnets' => $jotnets,
- '$title' => htmlspecialchars($item['title']),
+ '$title' => $item['title'],
'$placeholdertitle' => L10n::t('Set title'),
'$category' => FileTag::fileToList($item['file'], 'category'),
'$placeholdercategory' => (Feature::isEnabled(local_user(),'categories') ? L10n::t("Categories \x28comma-separated list\x29") : ''),
// and we'll waste a bunch of time responding to it. Time that
// could've been spent doing something else.
- $summary = Strings::escapeHtml(trim(defaults($_POST, 'summary', '')));
- $desc = Strings::escapeHtml(trim(defaults($_POST, 'desc', '')));
- $location = Strings::escapeHtml(trim(defaults($_POST, 'location', '')));
+ $summary = trim(defaults($_POST, 'summary' , ''));
+ $desc = trim(defaults($_POST, 'desc' , ''));
+ $location = trim(defaults($_POST, 'location', ''));
$type = 'event';
- $action = ($event_id == '') ? 'new' : "event/" . $event_id;
- $onerror_path = "events/" . $action . "?summary=$summary&description=$desc&location=$location&start=$start_text&finish=$finish_text&adjust=$adjust&nofinish=$nofinish";
+ $params = [
+ 'summary' => $summary,
+ 'description' => $desc,
+ 'location' => $location,
+ 'start' => $start_text,
+ 'finish' => $finish_text,
+ 'adjust' => $adjust,
+ 'nofinish' => $nofinish,
+ ];
+
+ $action = ($event_id == '') ? 'new' : 'event/' . $event_id;
+ $onerror_path = 'events/' . $action . '?' . http_build_query($params, null, null, PHP_QUERY_RFC3986);
if (strcmp($finish, $start) < 0 && !$nofinish) {
notice(L10n::t('Event can not end before it has started.') . EOL);
if ($share) {
- $str_group_allow = !empty($_POST['group_allow']) ? perms2str($_POST['group_allow']) : '';
- $str_contact_allow = !empty($_POST['contact_allow']) ? perms2str($_POST['contact_allow']) : '';
- $str_group_deny = !empty($_POST['group_deny']) ? perms2str($_POST['group_deny']) : '';
- $str_contact_deny = !empty($_POST['contact_deny']) ? perms2str($_POST['contact_deny']) : '';
+ $str_group_allow = perms2str(defaults($_POST, 'group_allow' , ''));
+ $str_contact_allow = perms2str(defaults($_POST, 'contact_allow', ''));
+ $str_group_deny = perms2str(defaults($_POST, 'group_deny' , ''));
+ $str_contact_deny = perms2str(defaults($_POST, 'contact_deny' , ''));
// Undo the pseudo-contact of self, since there are real contacts now
if (strpos($str_contact_allow, '<' . $self . '>') !== false) {
if (intval($_REQUEST['preview'])) {
$html = Event::getHTML($datarray);
echo $html;
- killme();
+ exit();
}
$item_id = Event::store($datarray);
}
if ($a->argc > 1 && $a->argv[1] === 'json') {
+ header('Content-Type: application/json');
echo json_encode($events);
- killme();
+ exit();
}
if (!empty($_GET['id'])) {
$r[0]['about'] = '';
}
- $header = L10n::t('Connect/Follow');
-
$o = Renderer::replaceMacros($tpl, [
- '$header' => htmlentities($header),
- //'$photo' => ProxyUtils::proxifyUrl($ret['photo'], false, ProxyUtils::SIZE_SMALL),
+ '$header' => L10n::t('Connect/Follow'),
'$desc' => '',
'$pls_answer' => L10n::t('Please answer the following:'),
'$does_know_you' => ['knowyou', L10n::t('Does %s know you?', $ret['name']), false, '', [L10n::t('No'), L10n::t('Yes')]],
'$url_label' => L10n::t('Profile URL'),
'$myaddr' => $myaddr,
'$request' => $request,
- /*
- * @TODO commented out?
- '$location' => Friendica\Content\Text\BBCode::::convert($r[0]['location']),
- '$location_label'=> L10n::t('Location:'),
- '$about' => Friendica\Content\Text\BBCode::::convert($r[0]['about'], false, false),
- '$about_label' => L10n::t('About:'),
- */
'$keywords' => $r[0]['keywords'],
'$keywords_label'=> L10n::t('Tags:')
]);
// Move the contact data to the profile array so we can deliver it to
$profile = [
- 'name' => $contact['name'],
- 'nick' => $contact['nick'],
- 'addr' => defaults($contact, 'addr', $contact['url']),
- 'thumb' => ProxyUtils::proxifyUrl($contact['thumb'], false, ProxyUtils::SIZE_THUMB),
- 'url' => Contact::magicLink($contact['url']),
- 'nurl' => $contact['nurl'], // We additionally store the nurl as identifier
- 'location' => $contact['location'],
- 'gender' => $contact['gender'],
- 'about' => $contact['about'],
- 'network' => Strings::formatNetworkName($contact['network'], $contact['url']),
- 'tags' => $contact['keywords'],
- 'bd' => $contact['birthday'] <= DBA::NULL_DATE ? '' : $contact['birthday'],
+ 'name' => $contact['name'],
+ 'nick' => $contact['nick'],
+ 'addr' => defaults($contact, 'addr', $contact['url']),
+ 'thumb' => ProxyUtils::proxifyUrl($contact['thumb'], false, ProxyUtils::SIZE_THUMB),
+ 'url' => Contact::magicLink($contact['url']),
+ 'nurl' => $contact['nurl'], // We additionally store the nurl as identifier
+ 'location' => $contact['location'],
+ 'gender' => $contact['gender'],
+ 'about' => $contact['about'],
+ 'network_link' => Strings::formatNetworkName($contact['network'], $contact['url']),
+ 'tags' => $contact['keywords'],
+ 'bd' => $contact['birthday'] <= DBA::NULL_DATE ? '' : $contact['birthday'],
'account_type' => Contact::getAccountType($contact),
- 'actions' => $actions,
+ 'actions' => $actions,
];
if ($datatype == 'html') {
$tpl = Renderer::getMarkupTemplate('hovercard.tpl');
$tpl = Renderer::getMarkupTemplate('prv_message.tpl');
$o .= Renderer::replaceMacros($tpl, [
- '$header' => L10n::t('Send Private Message'),
- '$to' => L10n::t('To:'),
+ '$header' => L10n::t('Send Private Message'),
+ '$to' => L10n::t('To:'),
'$showinputs' => 'true',
- '$prefill' => $prefill,
- '$preid' => $preid,
- '$subject' => L10n::t('Subject:'),
- '$subjtxt' => !empty($_REQUEST['subject']) ? strip_tags($_REQUEST['subject']) : '',
- '$text' => !empty($_REQUEST['body']) ? Strings::escapeHtml(htmlspecialchars($_REQUEST['body'])) : '',
- '$readonly' => '',
- '$yourmessage' => L10n::t('Your message:'),
- '$select' => $select,
- '$parent' => '',
- '$upload' => L10n::t('Upload photo'),
- '$insert' => L10n::t('Insert web link'),
- '$wait' => L10n::t('Please wait'),
- '$submit' => L10n::t('Submit')
+ '$prefill' => $prefill,
+ '$preid' => $preid,
+ '$subject' => L10n::t('Subject:'),
+ '$subjtxt' => defaults($_REQUEST, 'subject', ''),
+ '$text' => defaults($_REQUEST, 'body', ''),
+ '$readonly' => '',
+ '$yourmessage'=> L10n::t('Your message:'),
+ '$select' => $select,
+ '$parent' => '',
+ '$upload' => L10n::t('Upload photo'),
+ '$insert' => L10n::t('Insert web link'),
+ '$wait' => L10n::t('Please wait'),
+ '$submit' => L10n::t('Submit')
]);
return $o;
}
$entries[0] = [
'id' => 'network',
- 'name' => htmlentities($contact['name']),
+ 'name' => $contact['name'],
'itemurl' => defaults($contact, 'addr', $contact['nurl']),
'thumb' => ProxyUtils::proxifyUrl($contact['thumb'], false, ProxyUtils::SIZE_THUMB),
'details' => $contact['location'],
$notif_content[] = Renderer::replaceMacros($tpl, [
'$type' => $notif['label'],
- '$header' => htmlentities($header),
+ '$header' => $header,
'$str_notifytype' => L10n::t('Notification type:'),
'$notify_type' => $notif['notify_type'],
'$dfrn_text' => $dfrn_text,
$a->page['aside'] = '';
}
- if ($a->argc > 1) {
- $which = htmlspecialchars($a->argv[1]);
- } else {
- $r = q("SELECT `nickname` FROM `user` WHERE `blocked` = 0 AND `account_expired` = 0 AND `account_removed` = 0 AND `verified` = 1 ORDER BY RAND() LIMIT 1");
- if (DBA::isResult($r)) {
- $a->internalRedirect('profile/' . $r[0]['nickname']);
- } else {
- Logger::log('profile error: mod_profile ' . $a->query_string, Logger::DEBUG);
- notice(L10n::t('Requested profile is not available.') . EOL);
- $a->error = 404;
- return;
- }
+ if ($a->argc < 2) {
+ System::httpExit(400);
}
+ $which = filter_var($a->argv[1], FILTER_SANITIZE_STRING, FILTER_FLAG_STRIP_LOW | FILTER_FLAG_STRIP_HIGH | FILTER_FLAG_STRIP_BACKTICK);
+
$profile = 0;
if (local_user() && $a->argc > 2 && $a->argv[2] === 'view') {
$which = $a->user['nickname'];
- $profile = htmlspecialchars($a->argv[1]);
+ $profile = filter_var($a->argv[1], FILTER_SANITIZE_NUMBER_INT);
} else {
DFRN::autoRedir($a, $which);
}
// When the remote page does support OWA, then we enforce the use of it
$basepath = Contact::getBasepath($contact_url);
- $serverret = Network::curl($basepath . '/magic');
- if ($serverret->isSuccess()) {
- $contact['issued-id'] = '';
- $contact['dfrn-id'] = '';
+ if ($basepath == System::baseUrl()) {
+ $use_magic = true;
+ } else {
+ $serverret = Network::curl($basepath . '/magic');
+ $use_magic = $serverret->isSuccess();
}
// Doing remote auth with dfrn.
- if (local_user() && (!empty($contact['dfrn-id']) || !empty($contact['issued-id'])) && empty($contact['pending'])) {
+ if (local_user() && !$use_magic && (!empty($contact['dfrn-id']) || !empty($contact['issued-id'])) && empty($contact['pending'])) {
$dfrn_id = $orig_id = (($contact['issued-id']) ? $contact['issued-id'] : $contact['dfrn-id']);
if ($contact['duplex'] && $contact['issued-id']) {
// Makes the connection request for friendica contacts easier
$_SESSION['fastlane'] = $contact['url'];
- $header = L10n::t('Disconnect/Unfollow');
-
$o = Renderer::replaceMacros($tpl, [
- '$header' => htmlentities($header),
+ '$header' => L10n::t('Disconnect/Unfollow'),
'$desc' => '',
'$pls_answer' => '',
'$does_know_you' => '',
Nav::setSelected('home');
- $nick = $a->argv[1];
- $r = q("SELECT * FROM `user` WHERE `nickname` = '%s' AND `blocked` = 0 LIMIT 1",
- DBA::escape($nick)
- );
-
- if (!DBA::isResult($r)) {
+ $user = DBA::selectFirst('user', [], ['nickname' => $a->argv[1], 'blocked' => false]);
+ if (!DBA::isResult($user)) {
System::httpExit(404, ["title" => L10n::t('Page not found.')]);
}
- $a->data['user'] = $r[0];
- $a->profile_uid = $r[0]['uid'];
- $is_owner = (local_user() && (local_user() == $a->profile_uid));
+ $a->data['user'] = $user;
+ $a->profile_uid = $user['uid'];
Profile::load($a, $a->argv[1]);
}
$is_owner = $a->profile['profile_uid'] == local_user();
- $o = "";
-
// tabs
- $o .= Profile::getTabs($a, $is_owner, $a->data['user']['nickname']);
+ $o = Profile::getTabs($a, $is_owner, $a->data['user']['nickname']);
if (!count($a->profile) || $a->profile['hide-friends']) {
notice(L10n::t('Permission denied.') . EOL);
return $o;
}
- $total = 0;
- $r = q("SELECT COUNT(*) AS `total` FROM `contact`
- WHERE `uid` = %d AND NOT `blocked` AND NOT `pending`
- AND NOT `hidden` AND NOT `archive`
- AND `network` IN ('%s', '%s', '%s', '%s')",
- intval($a->profile['uid']),
- DBA::escape(Protocol::ACTIVITYPUB),
- DBA::escape(Protocol::DFRN),
- DBA::escape(Protocol::DIASPORA),
- DBA::escape(Protocol::OSTATUS)
- );
- if (DBA::isResult($r)) {
- $total = $r[0]['total'];
- }
+ $condition = [
+ 'uid' => $a->profile['uid'],
+ 'blocked' => false,
+ 'pending' => false,
+ 'hidden' => false,
+ 'archive' => false,
+ 'network' => [Protocol::ACTIVITYPUB, Protocol::DFRN, Protocol::DIASPORA, Protocol::OSTATUS]
+ ];
+
+ $total = DBA::count('count', $condition);
+
$pager = new Pager($a->query_string);
- $r = q("SELECT * FROM `contact`
- WHERE `uid` = %d AND NOT `blocked` AND NOT `pending`
- AND NOT `hidden` AND NOT `archive`
- AND `network` IN ('%s', '%s', '%s', '%s')
- ORDER BY `name` ASC LIMIT %d, %d",
- intval($a->profile['uid']),
- DBA::escape(Protocol::ACTIVITYPUB),
- DBA::escape(Protocol::DFRN),
- DBA::escape(Protocol::DIASPORA),
- DBA::escape(Protocol::OSTATUS),
- $pager->getStart(),
- $pager->getItemsPerPage()
- );
- if (!DBA::isResult($r)) {
- info(L10n::t('No contacts.').EOL);
+ $params = ['order' => ['name' => false], 'limit' => [$pager->getStart(), $pager->getItemsPerPage()]];
+
+ $contacts_stmt = DBA::select('contact', [], $condition, $params);
+
+ if (!DBA::isResult($contacts_stmt)) {
+ info(L10n::t('No contacts.') . EOL);
return $o;
}
$contacts = [];
- foreach ($r as $rr) {
+ while ($contact = DBA::fetch($contacts_stmt)) {
/// @TODO This triggers an E_NOTICE if 'self' is not there
- if ($rr['self']) {
+ if ($contact['self']) {
continue;
}
- $contact_details = Contact::getDetailsByURL($rr['url'], $a->profile['uid'], $rr);
+ $contact_details = Contact::getDetailsByURL($contact['url'], $a->profile['uid'], $contact);
$contacts[] = [
- 'id' => $rr['id'],
- 'img_hover' => L10n::t('Visit %s\'s profile [%s]', $contact_details['name'], $rr['url']),
- 'photo_menu' => Contact::photoMenu($rr),
- 'thumb' => ProxyUtils::proxifyUrl($contact_details['thumb'], false, ProxyUtils::SIZE_THUMB),
- 'name' => htmlentities(substr($contact_details['name'], 0, 20)),
- 'username' => htmlentities($contact_details['name']),
- 'details' => $contact_details['location'],
- 'tags' => $contact_details['keywords'],
- 'about' => $contact_details['about'],
- 'account_type' => Contact::getAccountType($contact_details),
- 'url' => Contact::magicLink($rr['url']),
- 'sparkle' => '',
- 'itemurl' => (($contact_details['addr'] != "") ? $contact_details['addr'] : $rr['url']),
- 'network' => ContactSelector::networkToName($rr['network'], $rr['url']),
+ 'id' => $contact['id'],
+ 'img_hover' => L10n::t('Visit %s\'s profile [%s]', $contact_details['name'], $contact['url']),
+ 'photo_menu' => Contact::photoMenu($contact),
+ 'thumb' => ProxyUtils::proxifyUrl($contact_details['thumb'], false, ProxyUtils::SIZE_THUMB),
+ 'name' => substr($contact_details['name'], 0, 20),
+ 'username' => $contact_details['name'],
+ 'details' => $contact_details['location'],
+ 'tags' => $contact_details['keywords'],
+ 'about' => $contact_details['about'],
+ 'account_type' => Contact::getAccountType($contact_details),
+ 'url' => Contact::magicLink($contact['url']),
+ 'sparkle' => '',
+ 'itemurl' => (($contact_details['addr'] != "") ? $contact_details['addr'] : $contact['url']),
+ 'network' => ContactSelector::networkToName($contact['network'], $contact['url']),
];
}
+ DBA::close($contacts_stmt);
$tpl = Renderer::getMarkupTemplate("viewcontact_template.tpl");
$o .= Renderer::replaceMacros($tpl, [
- '$title' => L10n::t('Contacts'),
+ '$title' => L10n::t('Contacts'),
'$contacts' => $contacts,
'$paginate' => $pager->renderFull($total),
]);
$tpl = Renderer::getMarkupTemplate('wallmessage.tpl');
$o = Renderer::replaceMacros($tpl, [
- '$header' => L10n::t('Send Private Message'),
- '$subheader' => L10n::t('If you wish for %s to respond, please check that the privacy settings on your site allow private mail from unknown senders.', $user['username']),
- '$to' => L10n::t('To:'),
- '$subject' => L10n::t('Subject:'),
- '$recipname' => $user['username'],
- '$nickname' => $user['nickname'],
- '$subjtxt' => (!empty($_REQUEST['subject']) ? strip_tags($_REQUEST['subject']) : ''),
- '$text' => (!empty($_REQUEST['body']) ? Strings::escapeHtml(htmlspecialchars($_REQUEST['body'])) : ''),
- '$readonly' => '',
- '$yourmessage' => L10n::t('Your message:'),
- '$parent' => '',
- '$upload' => L10n::t('Upload photo'),
- '$insert' => L10n::t('Insert web link'),
- '$wait' => L10n::t('Please wait')
+ '$header' => L10n::t('Send Private Message'),
+ '$subheader' => L10n::t('If you wish for %s to respond, please check that the privacy settings on your site allow private mail from unknown senders.', $user['username']),
+ '$to' => L10n::t('To:'),
+ '$subject' => L10n::t('Subject:'),
+ '$recipname' => $user['username'],
+ '$nickname' => $user['nickname'],
+ '$subjtxt' => defaults($_REQUEST, 'subject', ''),
+ '$text' => defaults($_REQUEST, 'body', ''),
+ '$readonly' => '',
+ '$yourmessage'=> L10n::t('Your message:'),
+ '$parent' => '',
+ '$upload' => L10n::t('Upload photo'),
+ '$insert' => L10n::t('Insert web link'),
+ '$wait' => L10n::t('Please wait')
]);
return $o;
$save_label = $mode === 'text' ? L10n::t('Save') : L10n::t('Follow');
$values = [
- '$s' => htmlspecialchars($s),
+ '$s' => $s,
'$id' => $id,
'$action_url' => $url,
'$search_label' => L10n::t('Search'),
);
$returnVal = $returnVal ? $status : false;
+ $status = $this->checkFunction('json_encode',
+ L10n::t('JSON PHP module'),
+ L10n::t('Error: JSON PHP module required but not installed.'),
+ true
+ );
+ $returnVal = $returnVal ? $status : false;
+
return $returnVal;
}
use Friendica\Core\Renderer;
use Friendica\Core\System;
use Friendica\Database\DBA;
-use Friendica\Model\Contact;
use Friendica\Util\DateTimeFormat;
use Friendica\Util\Map;
+use Friendica\Util\Strings;
use Friendica\Util\XML;
/**
if ($simple) {
if (!empty($event['summary'])) {
- $o = "<h3>" . BBCode::convert($event['summary'], false, $simple) . "</h3>";
+ $o = "<h3>" . BBCode::convert(Strings::escapeHtml($event['summary']), false, $simple) . "</h3>";
}
if (!empty($event['desc'])) {
- $o .= "<div>" . BBCode::convert($event['desc'], false, $simple) . "</div>";
+ $o .= "<div>" . BBCode::convert(Strings::escapeHtml($event['desc']), false, $simple) . "</div>";
}
$o .= "<h4>" . L10n::t('Starts:') . "</h4><p>" . $event_start . "</p>";
}
if (!empty($event['location'])) {
- $o .= "<h4>" . L10n::t('Location:') . "</h4><p>" . BBCode::convert($event['location'], false, $simple) . "</p>";
+ $o .= "<h4>" . L10n::t('Location:') . "</h4><p>" . BBCode::convert(Strings::escapeHtml($event['location']), false, $simple) . "</p>";
}
return $o;
$o = '<div class="vevent">' . "\r\n";
- $o .= '<div class="summary event-summary">' . BBCode::convert($event['summary'], false, $simple) . '</div>' . "\r\n";
+ $o .= '<div class="summary event-summary">' . BBCode::convert(Strings::escapeHtml($event['summary']), false, $simple) . '</div>' . "\r\n";
$o .= '<div class="event-start"><span class="event-label">' . L10n::t('Starts:') . '</span> <span class="dtstart" title="'
. DateTimeFormat::utc($event['start'], (!empty($event['adjust']) ? DateTimeFormat::ATOM : 'Y-m-d\TH:i:s'))
}
if (!empty($event['desc'])) {
- $o .= '<div class="description event-description">' . BBCode::convert($event['desc'], false, $simple) . '</div>' . "\r\n";
+ $o .= '<div class="description event-description">' . BBCode::convert(Strings::escapeHtml($event['desc']), false, $simple) . '</div>' . "\r\n";
}
if (!empty($event['location'])) {
$o .= '<div class="event-location"><span class="event-label">' . L10n::t('Location:') . '</span> <span class="location">'
- . BBCode::convert($event['location'], false, $simple)
+ . BBCode::convert(Strings::escapeHtml($event['location']), false, $simple)
. '</span></div>' . "\r\n";
// Include a map of the location if the [map] BBCode is used.
$drop = [System::baseUrl() . '/events/drop/' . $event['id'] , L10n::t('Delete event') , '', ''];
}
- $title = strip_tags(html_entity_decode(BBCode::convert($event['summary']), ENT_QUOTES, 'UTF-8'));
+ $title = BBCode::convert(Strings::escapeHtml($event['summary']));
if (!$title) {
- list($title, $_trash) = explode("<br", BBCode::convert($event['desc']), 2);
- $title = strip_tags(html_entity_decode($title, ENT_QUOTES, 'UTF-8'));
+ list($title, $_trash) = explode("<br", BBCode::convert(Strings::escapeHtml($event['desc'])), 2);
}
$author_link = $event['author-link'];
$event['plink'] = Contact::magicLink($author_link, $plink);
$html = self::getHTML($event);
- $event['desc'] = BBCode::convert($event['desc']);
- $event['location'] = BBCode::convert($event['location']);
+ $event['summary'] = BBCode::convert(Strings::escapeHtml($event['summary']));
+ $event['desc'] = BBCode::convert(Strings::escapeHtml($event['desc']));
+ $event['location'] = BBCode::convert(Strings::escapeHtml($event['location']));
$event_list[] = [
'id' => $event['id'],
'start' => $start,
$profile['picdate'] = urlencode(defaults($profile, 'picdate', ''));
if (($profile['network'] != '') && ($profile['network'] != Protocol::DFRN)) {
- $profile['network_name'] = Strings::formatNetworkName($profile['network'], $profile['url']);
+ $profile['network_link'] = Strings::formatNetworkName($profile['network'], $profile['url']);
} else {
- $profile['network_name'] = '';
+ $profile['network_link'] = '';
}
Addon::callHooks('profile_sidebar_enter', $profile);
$p['about'] = BBCode::convert($p['about']);
}
- if (isset($p['address'])) {
- $p['address'] = BBCode::convert($p['address']);
- } elseif (isset($p['location'])) {
- $p['address'] = BBCode::convert($p['location']);
+ if (empty($p['address']) && !empty($p['location'])) {
+ $p['address'] = $p['location'];
}
if (isset($p['photo'])) {
$a->data['contact'] = $contact;
if (($contact['network'] != '') && ($contact['network'] != Protocol::DFRN)) {
- $networkname = Strings::formatNetworkName($contact['network'], $contact['url']);
+ $network_link = Strings::formatNetworkName($contact['network'], $contact['url']);
} else {
- $networkname = '';
+ $network_link = '';
}
- /// @TODO Add nice spaces
$vcard_widget = Renderer::replaceMacros(Renderer::getMarkupTemplate('vcard-widget.tpl'), [
'$name' => $contact['name'],
'$photo' => $contact['photo'],
'$url' => Model\Contact::MagicLink($contact['url']),
'$addr' => defaults($contact, 'addr', ''),
- '$network_name' => $networkname,
+ '$network_link' => $network_link,
'$network' => L10n::t('Network:'),
'$account_type' => Model\Contact::getAccountType($contact)
]);
$relation_text = '';
}
- $relation_text = sprintf($relation_text, htmlentities($contact['name']));
+ $relation_text = sprintf($relation_text, $contact['name']);
$url = Model\Contact::magicLink($contact['url']);
if (strpos($url, 'redir/') === 0) {
'$profileurllabel'=> L10n::t('Profile URL'),
'$profileurl' => $contact['url'],
'$account_type' => Model\Contact::getAccountType($contact),
- '$location' => BBCode::convert($contact['location']),
+ '$location' => $contact['location'],
'$location_label' => L10n::t('Location:'),
'$xmpp' => BBCode::convert($contact['xmpp']),
'$xmpp_label' => L10n::t('XMPP:'),
$conversation = Model\Conversation::getByItemUri($item['uri']);
$item_uri = $item['uri'];
- $source = htmlspecialchars($conversation['source']);
+ $source = $conversation['source'];
}
$tpl = Renderer::getMarkupTemplate('debug/itemsource.tpl');
$o = Renderer::replaceMacros($tpl, [
- '$guid' => ['guid', L10n::t('Item Guid'), htmlentities(defaults($_REQUEST, 'guid', '')), ''],
+ '$guid' => ['guid', L10n::t('Item Guid'), defaults($_REQUEST, 'guid', ''), ''],
'$source' => $source,
'$item_uri' => $item_uri
]);
*/
public static function createEvent($activity, $item)
{
- $event['summary'] = $activity['name'];
- $event['desc'] = $activity['content'];
- $event['start'] = $activity['start-time'];
- $event['finish'] = $activity['end-time'];
+ $event['summary'] = HTML::toBBCode($activity['name']);
+ $event['desc'] = HTML::toBBCode($activity['content']);
+ $event['start'] = $activity['start-time'];
+ $event['finish'] = $activity['end-time'];
$event['nofinish'] = empty($event['finish']);
$event['location'] = $activity['location'];
- $event['adjust'] = true;
- $event['cid'] = $item['contact-id'];
- $event['uid'] = $item['uid'];
- $event['uri'] = $item['uri'];
- $event['edited'] = $item['edited'];
- $event['private'] = $item['private'];
- $event['guid'] = $item['guid'];
- $event['plink'] = $item['plink'];
+ $event['adjust'] = true;
+ $event['cid'] = $item['contact-id'];
+ $event['uid'] = $item['uid'];
+ $event['uri'] = $item['uri'];
+ $event['edited'] = $item['edited'];
+ $event['private'] = $item['private'];
+ $event['guid'] = $item['guid'];
+ $event['plink'] = $item['plink'];
$condition = ['uri' => $item['uri'], 'uid' => $item['uid']];
$ev = DBA::selectFirst('event', ['id'], $condition);
} elseif (in_array($item["verb"], [ACTIVITY_LIKE, ACTIVITY_DISLIKE])) {
$message = self::constructLike($item, $owner);
$type = "like";
- } else {
+ } elseif (!in_array($item["verb"], [ACTIVITY_FOLLOW])) {
$message = self::constructComment($item, $owner);
$type = "comment";
}
- if (!$message) {
+ if (empty($message)) {
return false;
}
$info = defaults($data, 'info', '');
$register_policy = defaults($data, 'register_policy', REGISTER_CLOSED);
if (in_array($register_policy, ['REGISTER_CLOSED', 'REGISTER_APPROVE', 'REGISTER_OPEN'])) {
- $register_policy = constant($data['register_policy']);
+ $register_policy = constant($register_policy);
} else {
Logger::log("Register policy '$register_policy' from $server_url is invalid.");
$register_policy = REGISTER_CLOSED; // set a default value
}
/**
- * @brief translate and format the networkname of a contact
+ * @brief Translate and format the network name of a contact
*
- * @param string $network Networkname of the contact (e.g. dfrn, rss and so on)
- * @param string $url The contact url
+ * @param string $network Network name of the contact (e.g. dfrn, rss and so on)
+ * @param string $url The contact url
*
- * @return string Formatted network name
+ * @return string Formatted network name
*/
- public static function formatNetworkName($network, $url = 0)
+ public static function formatNetworkName($network, $url = '')
{
- if ($network != "") {
- if ($url != "") {
- $network_name = '<a href="' . $url .'">' . ContactSelector::networkToName($network, $url) . "</a>";
+ if ($network != '') {
+ if ($url != '') {
+ $network_name = '<a href="' . $url .'">' . ContactSelector::networkToName($network, $url) . '</a>';
} else {
$network_name = ContactSelector::networkToName($network);
}
}
/**
- * @brief Remove intentation from a text
+ * @brief Remove indentation from a text
*
* @param string $text String to be transformed.
* @param string $chr Optional. Indentation tag. Default tab (\t).
$this->mockL10nT('Error: iconv PHP module required but not installed.', 1);
$this->mockL10nT('POSIX PHP module', 1);
$this->mockL10nT('Error: POSIX PHP module required but not installed.', 1);
+ $this->mockL10nT('JSON PHP module', 1);
+ $this->mockL10nT('Error: JSON PHP module required but not installed.', 1);
}
private function assertCheckExist($position, $title, $help, $status, $required, $assertionArray)
true,
$install->getChecks());
+ $this->mockFunctionL10TCalls();
+ $this->setFunctions(['json_encode' => false]);
+ $install = new Installer();
+ $this->assertFalse($install->checkFunctions());
+ $this->assertCheckExist(9,
+ 'JSON PHP module',
+ 'Error: JSON PHP module required but not installed.',
+ false,
+ true,
+ $install->getChecks());
+
$this->mockFunctionL10TCalls();
$this->setFunctions([
'curl_init' => true,
'openssl_public_encrypt' => true,
'mb_strlen' => true,
'iconv_strlen' => true,
- 'posix_kill' => true
+ 'posix_kill' => true,
+ 'json_encode' => true
]);
$install = new Installer();
$this->assertTrue($install->checkFunctions());
<h3 class="panel-title">{{$result.title}}</h3>
</div>
<div class="panel-body">
- {{$result.content}}
+ {{$result.content nofilter}}
</div>
</div>
{{/foreach}}
<input type="hidden" name="dfrn_url" value="{{$dfrn_url}}" />
<input type="hidden" name="confirm_key" value="{{$confirm_key}}" />
<input type="hidden" name="localconfirm" value="1" />
-{{$aes_allow}}
+{{$aes_allow nofilter}}
<label id="dfrn-request-homecoming-hide-label" for="dfrn-request-homecoming-hide">{{$hidethem}}</label>
-<input type="checkbox" name="hidden-contact" value="1" {{if $hidechecked}}checked="checked" {{/if}} />
+<input type="checkbox" name="hidden-contact" value="1" />
<div id="dfrn-request-homecoming-submit-wrapper" >
-
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional //EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
</head>
<body>
-<table style="border:1px solid #ccc">
+ <table style="border:1px solid #ccc">
<tbody>
- <tr><td colspan="2" style="background:#084769; color:#FFFFFF; font-weight:bold; font-family:'lucida grande', tahoma, verdana,arial, sans-serif; padding: 4px 8px; vertical-align: middle; font-size:16px; letter-spacing: -0.03em; text-align: left;"><img style="width:32px;height:32px; float:left;" src='{{$siteurl}}/images/friendica-32.png'><div style="padding:7px; margin-left: 5px; float:left; font-size:18px;letter-spacing:1px;">{{$product}}</div><div style="clear: both;"></div></td></tr>
-
+ <tr>
+ <td colspan="2" style="background:#084769; color:#FFFFFF; font-weight:bold; font-family:'lucida grande', tahoma, verdana,arial, sans-serif; padding: 4px 8px; vertical-align: middle; font-size:16px; letter-spacing: -0.03em; text-align: left;">
+ <img style="width:32px;height:32px; float:left;" src='{{$siteurl}}/images/friendica-32.png'>
+ <div style="padding:7px; margin-left: 5px; float:left; font-size:18px;letter-spacing:1px;">{{$product}}</div>
+ <div style="clear: both;"></div>
+ </td>
+ </tr>
- <tr><td style="padding-top:22px;" colspan="2">{{$preamble}}</td></tr>
+ <tr><td colspan="2" style="padding-top:22px;">{{$preamble nofilter}}</td></tr>
-
- {{if $content_allowed}}
+{{if $content_allowed}}
{{if $source_photo}}
- <tr><td style="padding-left:22px;padding-top:22px;width:60px;" valign="top" rowspan=3><a href="{{$source_link}}"><img style="border:0px;width:48px;height:48px;" src="{{$source_photo}}"></a></td>
- <td style="padding-top:22px;"><a href="{{$source_link}}">{{$source_name}}</a></td></tr>
- {{/if}}
- <tr><td style="font-weight:bold;padding-bottom:5px;">{{$title}}</td></tr>
- <tr><td style="padding-right:22px;">{{$htmlversion}}</td></tr>
- {{/if}}
- <tr><td style="padding-top:11px;" colspan="2">{{$hsitelink}}</td></tr>
- <tr><td style="padding-bottom:11px;" colspan="2">{{$hitemlink}}</td></tr>
- <tr><td></td><td>{{$thanks}}</td></tr>
- <tr><td></td><td>{{$site_admin}}</td></tr>
+ <tr>
+ <td style="padding-left:22px;padding-top:22px;width:60px;" valign="top" rowspan=3><a href="{{$source_link}}"><img style="border:0px;width:48px;height:48px;" src="{{$source_photo}}"></a></td>
+ <td style="padding-top:22px;"><a href="{{$source_link}}">{{$source_name}}</a></td>
+ </tr>
+ {{/if}}
+ <tr><td style="font-weight:bold;padding-bottom:5px;">{{$title}}</td></tr>
+ <tr><td style="padding-right:22px;">{{$htmlversion nofilter}}</td></tr>
+{{/if}}
+ <tr><td colspan="2" style="padding-top:11px;">{{$hsitelink nofilter}}</td></tr>
+ <tr><td colspan="2" style="padding-bottom:11px;">{{$hitemlink nofilter}}</td></tr>
+ <tr><td></td><td>{{$thanks}}</td></tr>
+ <tr><td></td><td>{{$site_admin}}</td></tr>
</tbody>
-</table>
+ </table>
</body>
</html>
-
</div>
<div class="profile-details">
<span class="profile-addr">{{$profile.addr}}</span>
- {{if $profile.network}}<span class="profile-network"> ({{$profile.network}})</span>{{/if}}
+ {{if $profile.network_link}}<span class="profile-network">({{$profile.network_link nofilter}})</span>{{/if}}
</div>
{{*{{if $profile.about}}<div class="profile-details profile-about">{{$profile.about nofilter}}</div>{{/if}}*}}
{{/if}}
{{if $tags.2}}<div id="tag-remove"><a href="{{$tags.2}}">{{$tags.3}}</a></div>{{/if}}
-{{if $edit}}{{$edit}}{{/if}}
+{{if $edit}}{{$edit nofilter}}{{/if}}
{{if $likebuttons}}
<div id="photo-like-div">
- {{$likebuttons}}
- {{$like}}
- {{$dislike}}
+ {{$likebuttons nofilter}}
+ {{$like nofilter}}
+ {{$dislike nofilter}}
</div>
{{/if}}
-{{$comments}}
+{{$comments nofilter}}
{{$paginate nofilter}}
<div id="profile-photo-wrapper"><a href="{{$profile.url}}"><img class="photo u-photo" width="175" height="175" src="{{$profile.photo}}" alt="{{$profile.name}}"></a></div>
{{/if}}
{{if $account_type}}<div class="account-type">{{$account_type}}</div>{{/if}}
- {{if $profile.network_name}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$profile.network_name nofilter}}</dd></dl>{{/if}}
+ {{if $profile.network_link}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$profile.network_link nofilter}}</dd></dl>{{/if}}
{{if $location}}
<dl class="location"><dt class="location-label">{{$location}}</dt>
<dd class="adr h-adr">
<div id="profile-photo-wrapper"><img class="vcard-photo photo u-photo" style="width: 175px; height: 175px;" src="{{$photo}}" alt="{{$name}}" /></div>
{{/if}}
{{if $account_type}}<div class="account-type">{{$account_type}}</div>{{/if}}
- {{if $network_name}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$network_name}}</dd></dl>{{/if}}
+ {{if $network_link}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$network_link nofilter}}</dd></dl>{{/if}}
<div id="profile-vcard-break"></div>
</div>
-
+<div class="generic-page-wrapper">
<h3>{{$header}}</h3>
<div id="prvmail-end"></div>
</form>
</div>
+</div>
{{if $account_type}}<div class="account-type">{{$account_type}}</div>{{/if}}
- {{if $profile.network_name}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$profile.network_name nofilter}}</dd></dl>{{/if}}
+ {{if $profile.network_link}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$profile.network_link nofilter}}</dd></dl>{{/if}}
{{if $location}}
<dl class="location"><dt class="location-label">{{$location}}</dt>
{/if}
{if $photo_menu.edit}
<a class="contact-action-link btn-link" href="{$photo_menu.edit.1}" data-toggle="tooltip" title="{$photo_menu.edit.0}">
- <i class="fa fa-pencil" aria-hidden="true"></i>
+ <i class="fa fa-user" aria-hidden="true"></i>
</a>
{/if}
{if $photo_menu.drop}
</span>
</div>
<div class="event-card-content media-body">
- <div class="event-title event-card-title summary event-summary">{{$title}}</div>
+ <div class="event-title event-card-title summary event-summary">{{$title nofilter}}</div>
+
{{* If there is a map, we insert a button for showing/hiding the map *}}
{{if $location.map}}<button id="event-map-btn-{{$id}}" class="event-map-btn btn-link fakelink nav nav-pills preferences" data-map-id="event-location-map-{{$id}}" data-show-label="{{$show_map_label}}" data-hide-label="{{$hide_map_label}}">{{$map_btn_label}}</button>{{/if}}
<div class="event-property">
<div class="form-group field textarea">
<label for="id_{{$field.0}}">{{$field.1}}</label>
- <textarea class="form-control text-autosize" name="{{$field.0}}" id="id_{{$field.0}}" {{if $field.4}}{{$field.4}}{{/if}} aria-describedby="{{$field.0}}_tip">{{$field.2 nofilter}}</textarea>
+ <textarea class="form-control text-autosize" name="{{$field.0}}" id="id_{{$field.0}}" {{if $field.4}}{{$field.4}}{{/if}} aria-describedby="{{$field.0}}_tip">{{$field.2}}</textarea>
{{if $field.3}}
<span class="help-block" id="{{$field.0}}_tip" role="tooltip">{{$field.3 nofilter}}</span>
{{/if}}
{{/if}}
{{* The part for editing the photo - only available for the edit subpage *}}
- {{if $edit}}{{$edit}}{{/if}}
+ {{if $edit}}{{$edit nofilter}}{{/if}}
{{if $likebuttons}}
<div id="photo-like-div">
- {{$likebuttons}}
- {{$like}}
- {{$dislike}}
+ {{$likebuttons nofilter}}
+ {{$like nofilter}}
+ {{$dislike nofilter}}
</div>
{{/if}}
<hr>
{{* Insert the comments *}}
<div id="photo-comment-wrapper-{{$id}}" class="photo-comment-wrapper">
- {{$comments}}
+ {{$comments nofilter}}
</div>
{{$paginate nofilter}}
{{if $account_type}}<div class="account-type">{{$account_type}}</div>{{/if}}
- {{if $network_name}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$network_name nofilter}}</dd></dl>{{/if}}
+ {{if $network_link}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$network_link nofilter}}</dd></dl>{{/if}}
</div>
</div>
</div>
{{/if}}
{{if $tags.2}}<div id="tag-remove"><a href="{{$tags.2}}">{{$tags.3}}</a></div>{{/if}}
-{{if $edit}}{{$edit}}{{/if}}
+{{if $edit}}{{$edit nofilter}}{{/if}}
{{if $likebuttons}}
<div id="photo-like-div">
- {{$likebuttons}}
- {{$like}}
- {{$dislike}}
+ {{$likebuttons nofilter}}
+ {{$like nofilter}}
+ {{$dislike nofilter}}
</div>
{{/if}}
<div class="wall-item-comment-wrapper photo">
- {{$comments}}
+ {{$comments nofilter}}
</div>
{{$paginate nofilter}}
{{if $account_type}}<div class="account-type">{{$account_type}}</div>{{/if}}
- {{if $profile.network_name}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$profile.network_name nofilter}}</dd></dl>{{/if}}
+ {{if $profile.network_link}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$profile.network_link nofilter}}</dd></dl>{{/if}}
{{if $location}}
<dl class="location"><dt class="location-label">{{$location}}</dt>
{{/if}}
{{if $tags.2}}<div id="tag-remove"><a href="{{$tags.2}}">{{$tags.3}}</a></div>{{/if}}
-{{if $edit}}{{$edit}}{{/if}}
+{{if $edit}}{{$edit nofilter}}{{/if}}
{{if $likebuttons}}
<div id="photo-like-div">
- {{$likebuttons}}
- {{$like}}
- {{$dislike}}
+ {{$likebuttons nofilter}}
+ {{$like nofilter}}
+ {{$dislike nofilter}}
</div>
{{/if}}
<div class="wall-item-comment-wrapper photo">
-{{$comments}}
+ {{$comments nofilter}}
</div>
{{$paginate nofilter}}
{{/if}}
{{if $account_type}}<div class="account-type">{{$account_type}}</div>{{/if}}
- {{if $profile.network_name}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$profile.network_name nofilter}}</dd></dl>{{/if}}
+ {{if $profile.network_link}}<dl class="network"><dt class="network-label">{{$network}}</dt><dd class="x-network">{{$profile.network_link nofilter}}</dd></dl>{{/if}}
{{if $location}}
<dl class="location"><dt class="location-label">{{$location}}</dt>
<dd class="adr h-adr">