Files
SEONexus/code/app/home/view/haoZi/pc/getSearchNovel.html
2025-04-24 01:20:07 +08:00

121 lines
4.8 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{extend name="basePc" /}
{block name="get-data"}
{novel:pagerexp page="$Request.get.page" limit="30"
key="$Request.get.keyword"
d_key="d_key"
d_val="Novel" n_num="total"
p_val="page_data" button_num="10" cache_life="86400" func="generateSearchPager" export_name="resData" /}
{site:grm page_code="pc_novel_search" diff="$Request.url" num="30" g_key="arrGrm" /}
{/block}
{block name="title"}{site:replace code="NOVEL@GETSEARCHNOVEL@TITLE"}{/block}
{block name="keywords"}{site:replace code="NOVEL@GETSEARCHNOVEL@KEYWORDS"}{/block}
{block name="description"}{site:replace code="NOVEL@GETSEARCHNOVEL@DESCRIPTION"}{/block}
{block name="head"}
<!-- 社交媒体标签 -->
<meta property="og:title" content={site:replace code="NOVEL@GETSEARCHNOVEL@TITLE"} />
<meta property="og:description" content='{site:replace code="NOVEL@GETSEARCHNOVEL@DESCRIPTION"}' />
<meta property="og:url" content="https://{$DomainModel->d_domain}{site:souurl key='$Request.get.keyword' p='1'/}" />
<meta property="og:type" content="book" />
<meta property="og:site_name" content="{$DomainModel->d_name}">
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:title" content="{$Request.get.keyword} - {$DomainModel->d_name}搜索 - 第{$Request.get.intPage}页">
<meta name="twitter:description" content="{$Request.get.keyword}搜索结果第{$Request.get.intPage}页,免费阅读小说,快来体验!">
<!-- 结构化数据 -->
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "SearchResultsPage",
"url": "https://{$DomainModel->d_name}{site:souurl key='$Request.get.keyword' p='1'/}",
"name": "{$DomainModel->d_name} - {$DomainModel->d_name}搜索 第{$Request.get.intPage}页",
"description": "搜索‘{$Request.get.keyword}’结果第{$Request.get.intPage}页,提供{$Request.get.keyword}创作的小说免费阅读。",
"datePublished": "{$arrNovel['n_update_time'] ?? time()}",
"mainEntity": {
"@type": "Book",
"name": "{$DomainModel->d_name}",
"author": {
"@type": "Person",
"name": "{$DomainModel->d_name}"
},
"url": "https://{$DomainModel->d_domain}"
}
}
</script>
{/block}
{block name="head-js"}{/block}
{block name="logo-html"}
<h2>
<a href="{$strPcPath}/">
{$DomainModel->d_name}-{$DomainModel->d_text_logo}
</a>
</h2>
{/block}
{block name="main"}
<div class="content">
<div class="find">
<div class="fi_t">
<h1>{$Request.get.keyword}搜索结果 - {$DomainModel->d_name} 第{$Request.get.page}页</h1>
<div class="result search_tip">
搜索<span style="color:red">“{$Request.get.keyword}”</span>相关结果共有 <span style="color:red">{$resData.p_data.total}</span> 部小说
</div>
</div>
</div>
<div class="result" mod="search_data_list">
{if empty($resData.data)}
<p style="text-align: center;line-height: 60px">没有相关数据</p>
{else}
<ul>
{foreach $resData.data as $key=>$Novel}
{include file="pc/public/shukuNovelList" start="0"/}
{/foreach}
</ul>
{/if}
<!--页码切换 开始-->
<div class="changepage">
<ul class="pagination">
{volist name="resData.p_data.pager" id="vo" key="k"}
{switch $vo.label}
{case value="上一页"}
{if $resData.p_data.page == 1}
<li class="disabled"><span>«</span></li>
{else}
<li><a href="{$strPcPath}{$vo.url}">«</a></li>
{/if}
{/case}
{case value="下一页"}
{if $resData.p_data.page >= $resData.p_data.total}
<li class="disabled"><span>»</span></li>
{else}
<li><a href='{$strPcPath}{$vo.url}'>»</a></li>
{/if}
{/case}
{case value="..."}
<li class="disabled"><span>...</span></li>
{/case}
{default /}
{if preg_match('/^\d+$/', $vo.label)}
<li class='{eq name="vo.label" value="$resData.p_data.page"}active {/eq}'>
<a href="{$strPcPath}{$vo.url}">{$vo.label}</a>
</li>
{/if}
{/switch}
{/volist}
</ul>
</div>
<!--页码切换 结束-->
</div>
</div>
{/block}
{block name="customize"} {/block}