update function calls to moved class.
//$txt = urldecode(requestdata('status'));
if ((strpos($txt, '<') !== false) || (strpos($txt, '>') !== false)) {
- $txt = html2bb_video($txt);
+ $txt = HTML::htmlToBBVideo($txt);
$config = HTMLPurifier_Config::createDefault();
$config->set('Cache.DefinitionImpl', null);
$purifier = new HTMLPurifier($config);
if (requestdata('htmlstatus')) {
$txt = requestdata('htmlstatus');
if ((strpos($txt, '<') !== false) || (strpos($txt, '>') !== false)) {
- $txt = html2bb_video($txt);
+ $txt = HTML::htmlToBBVideo($txt);
$config = HTMLPurifier_Config::createDefault();
$config->set('Cache.DefinitionImpl', null);
use Friendica\Content\Nav;
use Friendica\Content\Pager;
use Friendica\Content\Widget;
+use Friendica\Content\Text\HTML;
use Friendica\Core\ACL;
use Friendica\Core\Addon;
use Friendica\Core\Config;
$o = Renderer::replaceMacros($tpl, [
'$title' => L10n::t('Saved Searches'),
'$add' => L10n::t('add'),
- '$searchbox' => search($search, 'netsearch-box', $srchurl, true),
+ '$searchbox' => HTML::search($search, 'netsearch-box', $srchurl, true),
'$saved' => $saved,
]);
if (!$update) {
if (PConfig::get(local_user(), 'system', 'infinite_scroll')) {
- $o .= scroll_loader();
+ $o .= HTML::scrollLoader();
} else {
$o .= $pager->renderMinimal(count($items));
}
use Friendica\Core\L10n;
use Friendica\Core\PConfig;
use Friendica\Core\Protocol;
+use Friendica\Content\Text\HTML;
use Friendica\Database\DBA;
use Friendica\Model\Profile;
foreach($members as $member) {
if ($member['url']) {
$member['click'] = 'profChangeMember(' . $profile['id'] . ',' . $member['id'] . '); return true;';
- $o .= micropro($member,true,'mpprof', $textmode);
+ $o .= HTML::micropro($member,true,'mpprof', $textmode);
}
}
$o .= '</div><div id="prof-members-end"></div>';
foreach($r as $member) {
if (!in_array($member['id'],$ingroup)) {
$member['click'] = 'profChangeMember(' . $profile['id'] . ',' . $member['id'] . '); return true;';
- $o .= micropro($member,true,'mpprof',$textmode);
+ $o .= HTML::micropro($member,true,'mpprof',$textmode);
}
}
}
use Friendica\Content\Feature;
use Friendica\Content\Nav;
use Friendica\Content\Pager;
+use Friendica\Content\Text\HTML;
use Friendica\Core\Cache;
use Friendica\Core\Config;
use Friendica\Core\L10n;
'name' => "search-header",
'$title' => L10n::t("Search"),
'$title_size' => 3,
- '$content' => search($search,'search-box','search',((local_user()) ? true : false), false)
+ '$content' => HTML::search($search,'search-box','search',((local_user()) ? true : false), false)
]);
if (strpos($search,'#') === 0) {
use Friendica\Core\Protocol;
use Friendica\Content\Feature;
+use Friendica\Content\Text\HTML;
use Friendica\Core\L10n;
use Friendica\Core\Renderer;
use Friendica\Core\System;
$total_shown = 0;
$forumlist = '';
foreach ($contacts as $contact) {
- $forumlist .= micropro($contact, false, 'forumlist-profile-advanced');
+ $forumlist .= HTML::micropro($contact, false, 'forumlist-profile-advanced');
$total_shown ++;
if ($total_shown == $show_total) {
break;
$contacts = L10n::tt('%d Contact', '%d Contacts', $total);
$micropro = [];
foreach ($r as $rr) {
- $micropro[] = micropro($rr, true, 'mpfriend');
+ $micropro[] = self::micropro($rr, true, 'mpfriend');
}
}
}
use Friendica\Content\Feature;
use Friendica\Content\ForumManager;
use Friendica\Content\Text\BBCode;
+use Friendica\Content\Text\HTML;
use Friendica\Core\Addon;
use Friendica\Core\Cache;
use Friendica\Core\Config;
$updated = '';
$contacts = 0;
if (!$block) {
- $contact_block = contact_block();
+ $contact_block = HTML::contactBlock();
if (is_array($a->profile) && !$a->profile['hide-friends']) {
$r = q(
}
if ($a->profile['homepage']) {
- $profile['homepage'] = [L10n::t('Homepage:'), linkify($a->profile['homepage'])];
+ $profile['homepage'] = [L10n::t('Homepage:'), HTML::toLink($a->profile['homepage'])];
}
if ($a->profile['hometown']) {
- $profile['hometown'] = [L10n::t('Hometown:'), linkify($a->profile['hometown'])];
+ $profile['hometown'] = [L10n::t('Hometown:'), HTML::toLink($a->profile['hometown'])];
}
if ($a->profile['pub_keywords']) {
/// @todo Do we really need this check for HTML elements? (It was copied from the old function)
if ((strpos($item['body'], '<') !== false) && (strpos($item['body'], '>') !== false)) {
$base_url = get_app()->getBaseURL();
- $item['body'] = reltoabs($item['body'], $base_url);
+ $item['body'] = HTML::relToAbs($item['body'], $base_url);
- $item['body'] = html2bb_video($item['body']);
+ $item['body'] = HTML::htmlToBBVideo($item['body']);
$item['body'] = OEmbed::HTML2BBCode($item['body']);