From 5456d7d2b91ecd801902ecc7adea7db94db79fa6 Mon Sep 17 00:00:00 2001 From: Eltrac <45323514+BigCoke233@users.noreply.github.com> Date: Fri, 19 Jul 2019 16:37:01 +0800 Subject: Bug Fix/CSS improve --- libs/Contents.php | 51 +++++++++++++++++++++++++++++---------------------- libs/Utils.php | 11 +++++------ 2 files changed, 34 insertions(+), 28 deletions(-) (limited to 'libs') diff --git a/libs/Contents.php b/libs/Contents.php index d441577..a868c2d 100644 --- a/libs/Contents.php +++ b/libs/Contents.php @@ -1,35 +1,42 @@ /s','
',$text);
-		//FancyBox
-	    $text = preg_replace('//s','
',$text); - //LazyLoad - $text = preg_replace('//','',$text); + $text = empty($last) ? $data : $last; + if ($widget instanceof Widget_Archive) { + //Prism 高亮 + $text = preg_replace('/
/s','
',$text);
+		    //FancyBox
+	        $text = preg_replace('//s','
',$text); + //LazyLoad + $text = preg_replace('//','',$text); - //气泡 - $text = preg_replace('/\[bubble\](.*?)\[\/bubble\]/s','

${1}

',$text); + //气泡 + $text = preg_replace('/\[bubble\](.*?)\[\/bubble\]/s','

${1}

',$text); - //Tip without var - $text = preg_replace('/\[tip\](.*?)\[\/tip\]/s','
${1}
',$text); - //Tip - $text = preg_replace('/\[tip type="(.*?)"\](.*?)\[\/tip\]/s','
${2}
',$text); + //Tip without var + $text = preg_replace('/\[tip\](.*?)\[\/tip\]/s','
${1}
',$text); + //Tip + $text = preg_replace('/\[tip type="(.*?)"\](.*?)\[\/tip\]/s','
${2}
',$text); - //解析友链盒子 - $reg = '/\[links\](.*?)\[\/links\]/s'; - $rp = ''; - $text = preg_replace($reg,$rp,$text); - //解析友链项目 - $reg = '/\[(.*?)\]\{(.*?)\}\((.*?)\)/s'; - $rp = '