mirror of
https://github.com/friendica/friendica
synced 2025-04-25 16:30:10 +00:00
When converting to HTML, hashtag addresses are now removed (only when the message is exported)
This commit is contained in:
parent
f7fbac2e2b
commit
d4240a265b
2 changed files with 10 additions and 0 deletions
|
@ -107,6 +107,10 @@ function html2plain($html, $wraplength = 75, $compact = false)
|
|||
|
||||
$message = str_replace("\r", "", $html);
|
||||
|
||||
// replace all hashtag addresses
|
||||
$pattern = '/#<a.*?href="(.*?)".*?>(.*?)<\/a>/is';
|
||||
$message = preg_replace($pattern, '#$2', $message);
|
||||
|
||||
$doc = new DOMDocument();
|
||||
$doc->preserveWhiteSpace = false;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue