diff options
author | Mario <mario@mariovavti.com> | 2024-05-03 13:38:45 +0200 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2024-05-03 13:38:45 +0200 |
commit | 262cebb5688ae6b73db38badc6d7a66db460a70c (patch) | |
tree | c3f700d08059094212ba40a85e1560740d1fbc13 /include/html2bbcode.php | |
parent | 219f0dfeca0cccc1870ca9da608d5004d43e67fb (diff) | |
download | volse-hubzilla-262cebb5688ae6b73db38badc6d7a66db460a70c.tar.gz volse-hubzilla-262cebb5688ae6b73db38badc6d7a66db460a70c.tar.bz2 volse-hubzilla-262cebb5688ae6b73db38badc6d7a66db460a70c.zip |
make parsing of li slightly more robust
Diffstat (limited to 'include/html2bbcode.php')
-rw-r--r-- | include/html2bbcode.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/html2bbcode.php b/include/html2bbcode.php index e1c0572f5..e0a9a630a 100644 --- a/include/html2bbcode.php +++ b/include/html2bbcode.php @@ -128,9 +128,9 @@ function html2bbcode($message) $message = preg_replace('/\<ul(.*?)\>/', '[list]', $message); $message = preg_replace('/\<ol(.*?)\>/', '[list=1]', $message); + $message = preg_replace('/\<li(.*?)\>/', '[*]', $message); $message = str_replace(['</ul>', '</ol>'], '[/list]', $message); - $message = str_replace(['<li><p>', '<li>'], '[*]', $message); - $message = str_replace(['</p></li>', '</li>'], '', $message); + $message = str_replace('</li>', '', $message); if(!$message) return; |