PC 端 页面 head
This commit is contained in:
@@ -4,22 +4,59 @@
|
||||
{block name="description"}{$strDescription??''}{/block}
|
||||
{block name="head"}
|
||||
<!-- 社交媒体标签 -->
|
||||
<meta property="og:title" content="{$strTitle??''}" />
|
||||
<meta property="og:description" content="{$strDescription??''}" />
|
||||
<meta property="og:url" content="{Request->DomainModel->d_domain}" />
|
||||
<meta property="og:type" content="article" />
|
||||
<meta property="og:title" content="{$arrNovel['og_novel_book_name']??'未知小说'}" />
|
||||
<meta property="og:description" content="{$strDescription??'暂无简介'}" />
|
||||
<meta property="og:url"
|
||||
content='https://{$DomainModel->d_domain}{site:nurl n_id="$arrNovel[n_id]" n_py="$arrNovel[og_novel_pin_yin]" /}' />
|
||||
<meta property="og:type" content="novel" />
|
||||
<meta property="og:image" content="{$arrNovel.n_cover_path ?? ''}" />
|
||||
<meta property="og:site_name" content="{$DomainModel->d_name}" />
|
||||
<meta property="og:novel:category" content="{$arrNovel.og_novel_category ?? ''}">
|
||||
<meta property="og:novel:author" content="{$arrNovel.og_novel_author ?? ''}">
|
||||
<meta property="og:novel:book_name" content="{$arrNovel.og_novel_book_name ?? ''}">
|
||||
<meta property="og:novel:read_url"
|
||||
content="https://{$DomainModel->d_domain}/pc/xiaoshuo/{$arrNovel.og_novel_pin_yin}-{$arrLatestChapter.n_id}/zhang-1">
|
||||
<meta property="og:novel:status" content="{$arrNovel.og_novel_status ?? ''}">
|
||||
<meta property="og:novel:update_time" content="{$arrNovel.og_novel_update_time ?? ''}">
|
||||
<meta property="og:novel:latest_chapter_name" content="{$arrLatestChapter.name}">
|
||||
<meta property="og:novel:latest_chapter_url"
|
||||
content="https://{$DomainModel->d_domain}/pc/xiaoshuo/{$arrNovel.og_novel_pin_yin}-{$arrLatestChapter.n_id}/zhang-{$arrLatestChapter.c_sort_num}">
|
||||
<!-- 可选:支持 Twitter Card -->
|
||||
<meta name="twitter:card" content="summary_large_image" />
|
||||
<meta name="twitter:title" content="{$arrNovel['og_novel_book_name'] ?? '未知小说'}" />
|
||||
<meta name="twitter:description" content="{$strDescription ?? '暂无简介'}" />
|
||||
<meta name="twitter:image" content="{$arrNovel.n_cover_path ?? ''}" />
|
||||
<!-- 结构化数据 -->
|
||||
<script type="application/ld+json">
|
||||
{
|
||||
"@context": "https://schema.org",
|
||||
"@type": "NewsArticle",
|
||||
"headline": "{$strTitle??''}",
|
||||
"description": "{$strDescription??''}",
|
||||
"datePublished": "2025-04-05"
|
||||
"@context": '{$DomainModel->d_domain}/{site:nurl n_id="$arrNovel[n_id]" n_py="$arrNovel[og_novel_pin_yin]" /}',
|
||||
"@type": "Book",
|
||||
"name": "{$arrNovel['og_novel_book_name'] ?? '未知小说'}",
|
||||
"description": "{$arrNovel['n_page_description'] ??'暂无简介'}",
|
||||
"author": {
|
||||
"@type": "Person",
|
||||
"name": "{$arrNovel['og_novel_author'] ??'佚名'}"
|
||||
},
|
||||
"publisher": {
|
||||
"@type": "Organization",
|
||||
"name": "{$DomainModel->d_name}",
|
||||
"url": "https://{$DomainModel->d_domain}"
|
||||
},
|
||||
"datePublished": "{$arrNovel['og_novel_update_time'] ?? time()}",
|
||||
"image": "{$Novel.n_cover_path ?? ''}",
|
||||
"url": '{site:nurl n_id="$arrNovel[n_id]" n_py="$arrNovel[og_novel_pin_yin]" /}',
|
||||
"genre": "{$arrNovel.og_novel_category ??''}",
|
||||
"inLanguage": "zh-CN",
|
||||
"bookFormat": "https://{$DomainModel->d_domain}/EBook",
|
||||
"aggregateRating": {
|
||||
"@type": "AggregateRating",
|
||||
"ratingValue": "4.5",
|
||||
"reviewCount": "100",
|
||||
},
|
||||
}
|
||||
</script>
|
||||
{block name="head-css"}
|
||||
<link rel="canonical" href='{Request->DomainModel->d_domain}/xiaoshuo/$arrNovel.og_novel_pin_yin-$arrNovel.n_id/mulu/zheng" /}'>
|
||||
<link rel="canonical" href='https://{$DomainModel->d_domain}/xiaoshuo/$arrNovel.og_novel_pin_yin-$arrNovel.n_id/mulu/zheng" /}'>
|
||||
{/block}
|
||||
{block name="head-js"}{/block}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user