mirror of
https://github.com/friendica/friendica
synced 2025-04-23 07:10:14 +00:00
Deprecate use of [*] BBCode tag for list items in favor of [li]
- It is conflicting with Markdown syntax
This commit is contained in:
parent
ede41166ae
commit
5b5c9ddc74
6 changed files with 46 additions and 45 deletions
|
@ -1549,9 +1549,6 @@ class BBCode
|
|||
// Check for centered text
|
||||
$text = preg_replace("(\[center\](.*?)\[\/center\])ism", '<div style="text-align:center;">$1</div>', $text);
|
||||
|
||||
// Check for list text
|
||||
$text = str_replace("[*]", "<li>", $text);
|
||||
|
||||
// Check for block-level custom CSS
|
||||
$text = preg_replace('#(?<=^|\n)\[style=(.*?)](.*?)\[/style](?:\n|$)#ism', '<div style="$1">$2</div>', $text);
|
||||
|
||||
|
@ -1591,6 +1588,10 @@ class BBCode
|
|||
$text = preg_replace("/\[li\](.*?)\[\/li\]/ism", '<li>$1</li>', $text);
|
||||
}
|
||||
|
||||
// Check for list text
|
||||
$text = str_replace("[*]", "<li>", $text);
|
||||
$text = str_replace("[li]", "<li>", $text);
|
||||
|
||||
$text = preg_replace("/\[th\](.*?)\[\/th\]/sm", '<th>$1</th>', $text);
|
||||
$text = preg_replace("/\[td\](.*?)\[\/td\]/sm", '<td>$1</td>', $text);
|
||||
$text = preg_replace("/\[tr\](.*?)\[\/tr\]/sm", '<tr>$1</tr>', $text);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue