From 605aa37ad35387cbd84d1efd7bd744b5f1eb166c Mon Sep 17 00:00:00 2001 From: Mario Date: Fri, 3 May 2024 11:50:29 +0000 Subject: apply li fixes to html2plain --- include/html2plain.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'include/html2plain.php') diff --git a/include/html2plain.php b/include/html2plain.php index 5cb7ee35d..88dce577d 100644 --- a/include/html2plain.php +++ b/include/html2plain.php @@ -129,6 +129,8 @@ function html2plain($html, $wraplength = 75, $compact = false) if(!$message) return; + $message = preg_replace('/\/', "\n*", $message); + $message = str_replace('', '', $message); $doc = new DOMDocument(); $doc->preserveWhiteSpace = false; @@ -178,7 +180,7 @@ function html2plain($html, $wraplength = 75, $compact = false) //node2bbcode($doc, 'ul', array(), "\n[list]", "[/list]\n"); //node2bbcode($doc, 'ol', array(), "\n[list=1]", "[/list]\n"); - node2bbcode($doc, 'li', array(), "\n* ", "\n"); + //node2bbcode($doc, 'li', array(), "\n* ", "\n"); node2bbcode($doc, 'hr', array(), "\n".str_repeat("-", 70)."\n", ""); -- cgit v1.2.3