hubzilla issue #1151 - activitypub mention gets bookmarked
This commit is contained in:
parent
a3ed0b94cd
commit
1f429a0033
@ -797,7 +797,7 @@ function xml2array($contents, $namespaces = true, $get_attributes=1, $priority =
|
|||||||
if($namespaces)
|
if($namespaces)
|
||||||
$parser = @xml_parser_create_ns("UTF-8",':');
|
$parser = @xml_parser_create_ns("UTF-8",':');
|
||||||
else
|
else
|
||||||
$parser = @xml_parser_create();
|
$parser = @xml_parser_create('UTF-8');
|
||||||
|
|
||||||
if(! $parser) {
|
if(! $parser) {
|
||||||
logger('xml2array: xml_parser_create: no resource');
|
logger('xml2array: xml_parser_create: no resource');
|
||||||
@ -807,7 +807,7 @@ function xml2array($contents, $namespaces = true, $get_attributes=1, $priority =
|
|||||||
xml_parser_set_option($parser, XML_OPTION_TARGET_ENCODING, "UTF-8");
|
xml_parser_set_option($parser, XML_OPTION_TARGET_ENCODING, "UTF-8");
|
||||||
// http://minutillo.com/steve/weblog/2004/6/17/php-xml-and-character-encodings-a-tale-of-sadness-rage-and-data-loss
|
// http://minutillo.com/steve/weblog/2004/6/17/php-xml-and-character-encodings-a-tale-of-sadness-rage-and-data-loss
|
||||||
xml_parser_set_option($parser, XML_OPTION_CASE_FOLDING, 0);
|
xml_parser_set_option($parser, XML_OPTION_CASE_FOLDING, 0);
|
||||||
xml_parser_set_option($parser, XML_OPTION_SKIP_WHITE, 1);
|
xml_parser_set_option($parser, XML_OPTION_SKIP_WHITE, 0);
|
||||||
@xml_parse_into_struct($parser, trim($contents), $xml_values);
|
@xml_parse_into_struct($parser, trim($contents), $xml_values);
|
||||||
@xml_parser_free($parser);
|
@xml_parser_free($parser);
|
||||||
|
|
||||||
|
@ -3273,9 +3273,9 @@ function cleanup_bbcode($body) {
|
|||||||
$body = preg_replace_callback('/\[zrl(.*?)\[\/(zrl)\]/ism','\red_escape_codeblock',$body);
|
$body = preg_replace_callback('/\[zrl(.*?)\[\/(zrl)\]/ism','\red_escape_codeblock',$body);
|
||||||
|
|
||||||
|
|
||||||
$body = preg_replace_callback("/([^\]\='".'"'."\/]|^|\#\^)(https?\:\/\/[a-zA-Z0-9\pL\:\/\-\?\&\;\.\=\@\_\~\#\%\$\!\\
|
$body = preg_replace_callback("/([^\]\='".'"'."\/\{]|^|\#\^)(https?\:\/\/[a-zA-Z0-9\pL\:\/\-\?\&\;\.\=\@\_\~\#\%\$\!\\
|
||||||
+\,\(\)]+)/ismu", '\nakedoembed', $body);
|
+\,\(\)]+)/ismu", '\nakedoembed', $body);
|
||||||
$body = preg_replace_callback("/([^\]\='".'"'."\/]|^|\#\^)(https?\:\/\/[a-zA-Z0-9\pL\:\/\-\?\&\;\.\=\@\_\~\#\%\$\!\\
|
$body = preg_replace_callback("/([^\]\='".'"'."\/\{]|^|\#\^)(https?\:\/\/[a-zA-Z0-9\pL\:\/\-\?\&\;\.\=\@\_\~\#\%\$\!\\
|
||||||
+\,\(\)]+)/ismu", '\red_zrl_callback', $body);
|
+\,\(\)]+)/ismu", '\red_zrl_callback', $body);
|
||||||
|
|
||||||
$body = preg_replace_callback('/\[\$b64zrl(.*?)\[\/(zrl)\]/ism','\red_unescape_codeblock',$body);
|
$body = preg_replace_callback('/\[\$b64zrl(.*?)\[\/(zrl)\]/ism','\red_unescape_codeblock',$body);
|
||||||
|
Reference in New Issue
Block a user