X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Fhtml2plain.php;h=1d5910d83bea975a11a02b2aef1e8c3eba01e68b;hb=45c2a4868efbf8f457914f87bee8553cc28fa77f;hp=54cc44794dc9e3a1ca96a622df0008bb78cd2b7b;hpb=9f4ef7c105371fee195b0c506772496e50ec8e7e;p=friendica.git diff --git a/include/html2plain.php b/include/html2plain.php index 54cc44794d..1d5910d83b 100644 --- a/include/html2plain.php +++ b/include/html2plain.php @@ -113,12 +113,6 @@ function html2plain($html, $wraplength = 75, $compact = false) $message = str_replace("\r", "", $html); - // replace all hashtag addresses - if (get_config("system", "remove_hashtags_on_export")) { - $pattern = '/#(.*?)<\/a>/is'; - $message = preg_replace($pattern, '#$2', $message); - } - $doc = new DOMDocument(); $doc->preserveWhiteSpace = false; @@ -185,8 +179,8 @@ function html2plain($html, $wraplength = 75, $compact = false) node2bbcode($doc, 'h6', array(), "\n\n*", "*\n"); // Problem: there is no reliable way to detect if it is a link to a tag or profile - //node2bbcode($doc, 'a', array('href'=>'/(.+)/'), ' $1 ', '', true); - node2bbcode($doc, 'a', array('href'=>'/(.+)/', 'rel'=>'oembed'), ' $1 ', '', true); + //node2bbcode($doc, 'a', array('href'=>'/(.+)/'), ' $1 ', ' ', true); + //node2bbcode($doc, 'a', array('href'=>'/(.+)/', 'rel'=>'oembed'), ' $1 ', '', true); //node2bbcode($doc, 'img', array('alt'=>'/(.+)/'), '$1', ''); //node2bbcode($doc, 'img', array('title'=>'/(.+)/'), '$1', ''); //node2bbcode($doc, 'img', array(), '', ''); @@ -239,4 +233,4 @@ function html2plain($html, $wraplength = 75, $compact = false) return(trim($message)); } - +?>