This commit is contained in:
杜恒 2021-02-22 12:57:50 +08:00
parent 82adc1f42c
commit 7d3aae523c
4 changed files with 6 additions and 5 deletions

View File

@ -29,7 +29,7 @@ function themeInit($self)
Helper::options()->commentsRequireMail = true;
/* 强奸用户要求无需填写url */
Helper::options()->commentsRequireURL = false;
/* 强制用户评论回复 */
/* 强制用户开启评论回复 */
Helper::options()->commentsThreaded = true;
/* 强制显示一页12篇文章 */
$self->parameter->pageSize = 12;

View File

@ -185,7 +185,7 @@ function _getAbstract($item, $type = true)
if ($item->fields->abstract) {
$abstract = $item->fields->abstract;
} else {
$abstract = Typecho_Common::subStr(strip_tags($item->excerpt), 0, 180, '...');;
$abstract = strip_tags($item->excerpt);
}
}
if ($abstract === '') $abstract = "暂无简介";

View File

@ -88,14 +88,14 @@ function _parseContent($post, $login)
$content = preg_replace_callback(
'/\{music-list\s*id="(\w*)"\s*\/\}/SU',
function ($matches) {
return '<iframe class="lazyload" data-src="//music.163.com/outchain/player?type=0&id=' . $matches[1] . '&auto=1&height=430" width="330" height="450"></iframe>';
return '<iframe class="lazyload" data-src="//music.163.com/outchain/player?type=0&id=' . $matches[1] . '&auto=0&height=430" width="330" height="450"></iframe>';
},
$content
);
$content = preg_replace_callback(
'/\{music\s*id="(\w*)"\s*\/\}/SU',
function ($matches) {
return '<iframe class="lazyload" data-src="//music.163.com/outchain/player?type=2&id=' . $matches[1] . '&auto=1&height=66" width="330" height="86"></iframe>';
return '<iframe class="lazyload" data-src="//music.163.com/outchain/player?type=2&id=' . $matches[1] . '&auto=0&height=66" width="330" height="86"></iframe>';
},
$content
);

View File

@ -64,7 +64,8 @@
</div>
<?php if ($comments->have()) : ?>
<?php $comments->listComments(); ?>
<?php $comments->pageNav(
<?php
$comments->pageNav(
'<svg class="icon icon-prev" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" width="12" height="12"><path d="M822.272 146.944l-396.8 396.8c-19.456 19.456-51.2 19.456-70.656 0-18.944-19.456-18.944-51.2 0-70.656l396.8-396.8c19.456-19.456 51.2-19.456 70.656 0 18.944 19.456 18.944 45.056 0 70.656z" fill="" p-id="9417"></path><path d="M745.472 940.544l-396.8-396.8c-19.456-19.456-19.456-51.2 0-70.656 19.456-19.456 51.2-19.456 70.656 0l403.456 390.144c19.456 25.6 19.456 51.2 0 76.8-26.112 19.968-51.712 19.968-77.312 0.512zM181.248 877.056c0-3.584 0-7.68 0.512-11.264h-0.512V151.552h0.512c-0.512-3.584-0.512-7.168-0.512-11.264 0-43.008 21.504-78.336 48.128-78.336s48.128 34.816 48.128 78.336c0 3.584 0 7.68-0.512 11.264h0.512V865.792h-0.512c0.512 3.584 0.512 7.168 0.512 11.264 0 43.008-21.504 78.336-48.128 78.336s-48.128-35.328-48.128-78.336z"></path></svg>',
'<svg class="icon icon-next" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" width="12" height="12"><path d="M822.272 146.944l-396.8 396.8c-19.456 19.456-51.2 19.456-70.656 0-18.944-19.456-18.944-51.2 0-70.656l396.8-396.8c19.456-19.456 51.2-19.456 70.656 0 18.944 19.456 18.944 45.056 0 70.656z" fill="" p-id="9417"></path><path d="M745.472 940.544l-396.8-396.8c-19.456-19.456-19.456-51.2 0-70.656 19.456-19.456 51.2-19.456 70.656 0l403.456 390.144c19.456 25.6 19.456 51.2 0 76.8-26.112 19.968-51.712 19.968-77.312 0.512zM181.248 877.056c0-3.584 0-7.68 0.512-11.264h-0.512V151.552h0.512c-0.512-3.584-0.512-7.168-0.512-11.264 0-43.008 21.504-78.336 48.128-78.336s48.128 34.816 48.128 78.336c0 3.584 0 7.68-0.512 11.264h0.512V865.792h-0.512c0.512 3.584 0.512 7.168 0.512 11.264 0 43.008-21.504 78.336-48.128 78.336s-48.128-35.328-48.128-78.336z"></path></svg>',
1,