parent
620455c4de
commit
20b14b053a
1 changed files with 13 additions and 12 deletions
|
@ -1697,12 +1697,12 @@ function item_body_set_hashtags(&$item) {
|
||||||
// mask hashtags inside of url, bookmarks and attachments to avoid urls in urls
|
// mask hashtags inside of url, bookmarks and attachments to avoid urls in urls
|
||||||
$item["body"] = preg_replace_callback("/\[url\=([$URLSearchString]*)\](.*?)\[\/url\]/ism",
|
$item["body"] = preg_replace_callback("/\[url\=([$URLSearchString]*)\](.*?)\[\/url\]/ism",
|
||||||
function ($match){
|
function ($match){
|
||||||
return("[url=".$match[1]."]".str_replace("#", "#", $match[2])."[/url]");
|
return("[url=".str_replace("#", "#", $match[1])."]".str_replace("#", "#", $match[2])."[/url]");
|
||||||
},$item["body"]);
|
},$item["body"]);
|
||||||
|
|
||||||
$item["body"] = preg_replace_callback("/\[bookmark\=([$URLSearchString]*)\](.*?)\[\/bookmark\]/ism",
|
$item["body"] = preg_replace_callback("/\[bookmark\=([$URLSearchString]*)\](.*?)\[\/bookmark\]/ism",
|
||||||
function ($match){
|
function ($match){
|
||||||
return("[bookmark=".$match[1]."]".str_replace("#", "#", $match[2])."[/bookmark]");
|
return("[bookmark=".str_replace("#", "#", $match[1])."]".str_replace("#", "#", $match[2])."[/bookmark]");
|
||||||
},$item["body"]);
|
},$item["body"]);
|
||||||
|
|
||||||
$item["body"] = preg_replace_callback("/\[attachment (.*)\](.*?)\[\/attachment\]/ism",
|
$item["body"] = preg_replace_callback("/\[attachment (.*)\](.*?)\[\/attachment\]/ism",
|
||||||
|
@ -1714,6 +1714,7 @@ function item_body_set_hashtags(&$item) {
|
||||||
$item["body"] = preg_replace("/#\[url\=([$URLSearchString]*)\](.*?)\[\/url\]/ism",
|
$item["body"] = preg_replace("/#\[url\=([$URLSearchString]*)\](.*?)\[\/url\]/ism",
|
||||||
"#$2", $item["body"]);
|
"#$2", $item["body"]);
|
||||||
|
|
||||||
|
|
||||||
foreach($tags as $tag) {
|
foreach($tags as $tag) {
|
||||||
if(strpos($tag,'#') !== 0)
|
if(strpos($tag,'#') !== 0)
|
||||||
continue;
|
continue;
|
||||||
|
|
Loading…
Reference in a new issue