mirror of
https://github.com/friendica/friendica
synced 2024-11-10 04:22:54 +00:00
BBCode - fixed syntax error
This commit is contained in:
parent
54bec2bc8e
commit
41663c7592
1 changed files with 2 additions and 2 deletions
|
@ -1364,8 +1364,8 @@ class BBCode extends BaseObject
|
|||
// We need no target="_blank" for local links
|
||||
// convert links start with System::baseUrl() as local link without the target="_blank" attribute
|
||||
$escapedBaseUrl = preg_quote(System::baseUrl(), '/');
|
||||
$text = preg_replace("/\[url\]($escapedBaseUrl[$URLSearchString]*)\[\/url\]/ism", '<a href="$1">$1</a>', $text);
|
||||
$text = preg_replace("/\[url\=($escapedBaseUrl[$URLSearchString]*)\](.*?)\[\/url\]/ism", '<a href="$1">$2</a>', $text);
|
||||
$text = preg_replace("/\[url\](".$escapedBaseUrl."[$URLSearchString]*)\[\/url\]/ism", '<a href="$1">$1</a>', $text);
|
||||
$text = preg_replace("/\[url\=(".$escapedBaseUrl."[$URLSearchString]*)\](.*?)\[\/url\]/ism", '<a href="$1">$2</a>', $text);
|
||||
|
||||
$text = preg_replace("/\[url\]([$URLSearchString]*)\[\/url\]/ism", '<a href="$1" target="_blank">$1</a>', $text);
|
||||
$text = preg_replace("/\[url\=([$URLSearchString]*)\](.*?)\[\/url\]/ism", '<a href="$1" target="_blank">$2</a>', $text);
|
||||
|
|
Loading…
Reference in a new issue