X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=view%2Ftheme%2Ffrio%2Ftheme.php;h=3f401612e2e0222533155d98733e3cca52c2d198;hb=d59cd7dfa4fff840dcab640ab5c194ededf7fc0b;hp=3c4d5120cf84dc46e9cf14e6c6ce69a210c2aebe;hpb=30c1cc0e8cec5438fd8fe36bd4ea00991dc01934;p=friendica.git diff --git a/view/theme/frio/theme.php b/view/theme/frio/theme.php index 3c4d5120cf..3f401612e2 100644 --- a/view/theme/frio/theme.php +++ b/view/theme/frio/theme.php @@ -6,7 +6,9 @@ * Author: Rabuzarus * */ + use Friendica\App; +use Friendica\Content\Text\Plaintext; use Friendica\Content\Widget; use Friendica\Core\Addon; use Friendica\Core\Config; @@ -15,7 +17,6 @@ use Friendica\Core\PConfig; use Friendica\Core\System; use Friendica\Database\DBM; use Friendica\Model\Profile; -use Friendica\Object\Image; $frio = "view/theme/frio"; @@ -90,10 +91,8 @@ function frio_uninstall() */ function frio_item_photo_links(App $a, &$body_info) { - $phototypes = Image::supportedTypes(); - $occurence = 1; - $p = bb_find_open_close($body_info['html'], ""); - + $occurence = 0; + $p = Plaintext::getBoundariesPosition($body_info['html'], ""); while ($p !== false && ($occurence++ < 500)) { $link = substr($body_info['html'], $p['start'], $p['end'] - $p['start']); $matches = []; @@ -112,7 +111,7 @@ function frio_item_photo_links(App $a, &$body_info) $body_info['html'] = str_replace($link, $newlink, $body_info['html']); } - $p = bb_find_open_close($body_info['html'], "", $occurence); + $p = Plaintext::getBoundariesPosition($body_info['html'], "", $occurence); } } @@ -302,7 +301,7 @@ function frio_acl_lookup(App $a, &$results) $search_txt = dbesc(protect_sprintf(preg_quote($results["search"]))); $searching = true; } - + $sql_extra = ''; if ($searching) { $sql_extra .= " AND (`attag` LIKE '%%" . dbesc($search_txt) . "%%' OR `name` LIKE '%%" . dbesc($search_txt) . "%%' OR `nick` LIKE '%%" . dbesc($search_txt) . "%%') ";