mirror of
https://git.friendi.ca/friendica/friendica.git
synced 2025-06-17 03:25:15 +02:00
Changed markdown to enable diaspora postings with images that contain links
This commit is contained in:
parent
04c31d194f
commit
2aa67d67f5
2 changed files with 9 additions and 4 deletions
|
@ -202,9 +202,9 @@ function bb2diaspora($Text,$preserve_nl = false, $fordiaspora = true) {
|
|||
// the following was added on 10-January-2012 due to an inability of Diaspora's
|
||||
// new javascript markdown processor to handle links with images as the link "text"
|
||||
// It is not optimal and may be removed if this ability is restored in the future
|
||||
if ($fordiaspora)
|
||||
$Text = preg_replace("/\[url\=([^\[\]]*)\]\s*\[img\](.*?)\[\/img\]\s*\[\/url\]/ism",
|
||||
"[url]$1[/url]\n[img]$2[/img]", $Text);
|
||||
//if ($fordiaspora)
|
||||
// $Text = preg_replace("/\[url\=([^\[\]]*)\]\s*\[img\](.*?)\[\/img\]\s*\[\/url\]/ism",
|
||||
// "[url]$1[/url]\n[img]$2[/img]", $Text);
|
||||
|
||||
// Convert it to HTML - don't try oembed
|
||||
$Text = bbcode($Text, $preserve_nl, false);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue