From 4c7eff848dd38e826787fbd29dd2d8185ba42278 Mon Sep 17 00:00:00 2001 From: Eltrac <45323514+BigCoke233@users.noreply.github.com> Date: Sat, 20 Jul 2019 12:41:10 +0800 Subject: =?UTF-8?q?=E8=A7=84=E8=8C=83=E4=BB=A3=E7=A0=81=E7=BB=93=E6=9E=84/?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E8=AE=BE=E7=BD=AE=E9=A1=B9/=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E9=83=A8=E5=88=86=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- functions.php | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'functions.php') diff --git a/functions.php b/functions.php index a4b1cbb..fb6d34d 100644 --- a/functions.php +++ b/functions.php @@ -7,6 +7,7 @@ require_once("libs/Contents.php"); * 注册文章解析 hook * 具体的解析代码需要在 Contents::parseContent() 方法中实现 * 解析不会改变数据库中的内容,体现在文章前台输出、RSS 输出时 + * From AlanDecode(https://imalan.cn) */ Typecho_Plugin::factory('Widget_Abstract_Contents')->contentEx = array('Contents','parseContent'); Typecho_Plugin::factory('Widget_Abstract_Contents')->excerptEx = array('Contents','parseContent'); @@ -15,9 +16,6 @@ Typecho_Plugin::factory('Widget_Abstract_Contents')->excerptEx = array('Contents * 主题启用时执行的方法 */ function themeInit() { - /** - * 重置某些设置项,采用数据库查询方式完成 - */ $db = Typecho_Db::get(); $query = $db->update('table.options')->rows(array('value'=>'0'))->where('name=?', 'commentsAntiSpam'); @@ -43,7 +41,7 @@ function themeInit() { */ function themeConfig($form) { //nav - $nav_position = new Typecho_Widget_Helper_Form_Element_Select('nav_position',array('0'=>'不固定','1'=>'固定'),'0','导航栏-是否固定','固定后,导航栏不会随滚动条滚动而移动在屏幕上的位置'); + $nav_position = new Typecho_Widget_Helper_Form_Element_Select('nav_position',array('0'=>'不固定','1'=>'固定'),'0','导航栏-是否固定','固定后,导航栏不会随滚动条滚动而移动在屏幕上的位置