mirror of
https://gitee.com/ulthon/ulthon_information.git
synced 2026-03-03 16:24:28 +08:00
优化文章seo声明;导出面板新增版权声明功能;
This commit is contained in:
16
app/common/tools/PostBlock.php
Normal file
16
app/common/tools/PostBlock.php
Normal file
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
namespace app\common\tools;
|
||||
|
||||
use think\facade\View;
|
||||
|
||||
class PostBlock
|
||||
{
|
||||
public static function copyright($model_post)
|
||||
{
|
||||
|
||||
return View::fetch(__DIR__ . '/post_block/copyright.html', [
|
||||
'post' => $model_post
|
||||
]);
|
||||
}
|
||||
}
|
||||
14
app/common/tools/post_block/copyright.html
Normal file
14
app/common/tools/post_block/copyright.html
Normal file
@@ -0,0 +1,14 @@
|
||||
<blockquote class="copyright">
|
||||
<p>
|
||||
<span>原文标题:</span>{$post->title}
|
||||
</p>
|
||||
<p>
|
||||
<span>原文地址:</span><a href="{$post->read_url}">{$post->read_url}</a>
|
||||
</p>
|
||||
<p>
|
||||
<span>原文平台:</span><a href="http://{:get_system_config('main_domain')}">{:get_system_config('site_name')}</a>
|
||||
</p>
|
||||
<p>
|
||||
<span>版权声明:</span>{:get_system_config('post_copyright')}
|
||||
</p>
|
||||
</blockquote>
|
||||
Reference in New Issue
Block a user