ripro主题美化教程(第四期)
本期教程内容:
文章标题美化
添加常见问题FAQ
效果演示请看本站
文章标题美化教程:
1. ripro -> parts -> single-header.php 文件,整体替换为如下代码
'h1') );
} else {
aug_entry_header( array( 'tag' => 'h1', 'link' => false ) );
}
get_template_part( 'parts/entry-subheading' );?>
作者 :
href="">
发布时间:
人阅读
2.ripro -> assets -> css-> diy.css 添加如下样式
/***文章标题美化***/
.sjblog-avatar {width: 50px;float: left;}
.sjblog-avatar img {float: left;border-radius: 50%;margin-right: 20px;}
.sjblog-tgroup{padding-left: 66px;padding-bottom: 20px;border-bottom: 1px solid #f5f5f5;margin-bottom: 20px;}
.sjblog-tgroup .entry-header{ margin-bottom: 0 !important;}
.article-content .entry-header .entry-title{padding-bottom:0;margin-bottom: 0 !important;border-bottom: none;}
.sjblog-name {padding-top:5px;display: block;font-size: 13px;color: #cdcdcd;}
.sjblog-name a{color: #cdcdcd;}
.sjblog-name a:hover{color: #2756fc;}
.sjblog-time {margin-left: 20px;}
添加“常见问题FAQ”教程:
1. ripro ->inc -> codestar-framework -> options -> options.theme.php 搜索“share_poster_img_qrcode”,在第一个“),”后添加如下代码
array(
'id' => 'is_show_faq',
'type' => 'switcher',
'title' => '是否显示常见问题FAQ',
'label' => '文章底部显示常见问题FAQ',
'default' => true,
),
array(
'id' => 'faq_help_field',
'type' => 'group',
'title' => '常见问题FAQ相关设置',
'max' => '6',
'fields' => array(
array(
'id' => '_matter',
'type' => 'text',
'title' => '常见问题',
'attributes' => array(
'style' => 'width: 100%;',
),
),
array(
'id' => '_answer',
'type' => 'textarea',
'title' => '问题答案',
),
),
'dependency' => array('is_show_faq', '==', 'true'),
'default' => array(
array(
'_matter' =>'免费下载或者VIP会员专享资源能否直接商用?',
'_answer' => '本站所有资源版权均属于原作者所有,这里所提供资源均只能用于参考学习用,请勿直接商用。若由于商用引起版权纠纷,一切责任均由使用者承担。更多说明请参考 VIP介绍。',
),
),
),
2. ripro -> parts ->author-box.php,在“
发表评论 (0)
请登录后再参与讨论