Commit 982d12d0 authored by Van's avatar Van

🎨 #12720 use macro-common_head.ftl for every page

parent f6457cbb
...@@ -17,22 +17,14 @@ ...@@ -17,22 +17,14 @@
along with this program. If not, see <https://www.gnu.org/licenses/>. along with this program. If not, see <https://www.gnu.org/licenses/>.
--> -->
<#include "../common-template/macro-common_head.ftl"/>
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="utf-8" /> <@head title="${adminConsoleLabel} - ${blogTitle}">
<meta http-equiv="X-UA-Compatible" content="IE=edge"> <link type="text/css" rel="stylesheet" href="${staticServePath}/scss/admin.css?${staticResourceVersion}" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"> <meta name="robots" content="fn__none" />
<meta name="copyright" content="B3log"> </@head>
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta http-equiv="Window-target" content="_top">
<meta name="robots" content="fn__none" />
<title>${adminConsoleLabel} - ${blogTitle}</title>
<link type="text/css" rel="stylesheet" href="${staticServePath}/scss/admin.css?${staticResourceVersion}" />
<link type="text/css" rel="stylesheet" href="https://cdn.jsdelivr.net/npm/highlight.js@9.15.6/styles/atom-one-light.min.css" />
<link rel="icon" type="image/png" href="${faviconURL}" />
<link rel="manifest" href="${servePath}/manifest.json">
</head> </head>
<body onhashchange="admin.setCurByHash();"> <body onhashchange="admin.setCurByHash();">
<div class="tip"><span id="loadMsg">${loadingLabel}</span></div> <div class="tip"><span id="loadMsg">${loadingLabel}</span></div>
......
...@@ -17,6 +17,9 @@ ...@@ -17,6 +17,9 @@
along with this program. If not, see <https://www.gnu.org/licenses/>. along with this program. If not, see <https://www.gnu.org/licenses/>.
--> -->
<script src="${staticServePath}/js/lib/compress/pjax.min.js"></script>
<script src="${staticServePath}/js/common${miniPostfix}.js?${staticResourceVersion}"></script>
<script src="${staticServePath}/skins/${skinDirName}/js/common${miniPostfix}.js?${staticResourceVersion}"></script>
<script> <script>
var Label = { var Label = {
"servePath": "${servePath}", "servePath": "${servePath}",
......
<#-- Solo - A small and beautiful blogging system written in Java. Copyright (c) 2010-2019, b3log.org & hacpai.com This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see <https://www.gnu.org/licenses/>. --> <#macro head title canonical description=''> <meta charset="utf-8" /> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" /> <meta name="theme-color" content="#3b3e43"> <meta name="apple-mobile-web-app-capable" content="yes"> <meta name="mobile-web-app-capable" content="yes" /> <meta name="apple-mobile-web-app-status-bar-style" content="black"> <meta name="format-detection" content="telephone=no" /> <title>${title}</title> <#if description != ''> <meta name="description" content="${description}"/> <meta property="og:description" content="${description}"/> <#elseif metaDescription??> <meta name="description" content="${metaDescription}"/> <meta property="og:description" content="${metaDescription}"/> <#else> <meta name="description" content="${blogTitle?html}。${blogSubtitle?html}"/> <meta property="og:description" content="${blogTitle?html}。${blogSubtitle?html}"/> </#if> <#if metaKeywords??> <meta name="keywords" content="${metaKeywords}"/> </#if> <link rel="dns-prefetch" href="${staticServePath}" /> <link rel="dns-prefetch" href="//cdn.jsdelivr.net" /> <link rel="preconnect" href="${staticServePath}"> <link rel="icon" type="image/png" href="${faviconURL}" /> <link rel="apple-touch-icon" href="${faviconURL}"> <link rel="shortcut icon" type="image/x-icon" href="${faviconURL}"> <meta name="copyright" content="B3log" /> <meta http-equiv="Window-target" content="_top" /> <meta property="og:locale" content="${langLabel}"/> <meta property="og:title" content="${title}"/> <meta property="og:site_name" content="${blogTitle?html}"/> <meta property="og:url" content="${servePath}${request.requestURI}<#if request.queryString??>?${request.queryString}</#if>"/> <meta property="og:image" content="${faviconURL}"/> <link rel="search" type="application/opensearchdescription+xml" title="${title}" href="/opensearch.xml"> <link href="${servePath}/rss.xml" title="RSS" type="application/rss+xml" rel="alternate" /> <link rel="manifest" href="${servePath}/manifest.json"> <link rel="canonical" href="${servePath}${canonical}"> <#nested> <link rel="stylesheet" href="${staticServePath}/skins/${skinDirName}/css/base.css?${staticResourceVersion}" /> <script src="${staticServePath}/js/lib/compress/pjax.min.js" defer></script> <script src="${staticServePath}/js/common${miniPostfix}.js?${staticResourceVersion}" defer></script> <script src="${staticServePath}/skins/${skinDirName}/js/common${miniPostfix}.js?${staticResourceVersion}" defer></script> ${htmlHead} </#macro> <#-- Solo - A small and beautiful blogging system written in Java. Copyright (c) 2010-2019, b3log.org & hacpai.com This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see <https://www.gnu.org/licenses/>. --> <#macro head title description=''> <meta charset="utf-8"/> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"/> <meta name="theme-color" content="#3b3e43"> <meta name="apple-mobile-web-app-capable" content="yes"> <meta name="mobile-web-app-capable" content="yes"/> <meta name="apple-mobile-web-app-status-bar-style" content="black"> <meta name="format-detection" content="telephone=no"/> <title>${title}</title> <#if description != ''> <meta name="description" content="${description}"/> <meta property="og:description" content="${description}"/> <#elseif metaDescription??> <meta name="description" content="${metaDescription}"/> <meta property="og:description" content="${metaDescription}"/> <#else> <meta name="description" content="${blogTitle?html}。${blogSubtitle?html}"/> <meta property="og:description" content="${blogTitle?html}。${blogSubtitle?html}"/> </#if> <#if metaKeywords??> <meta name="keywords" content="${metaKeywords}"/> </#if> <link rel="dns-prefetch" href="${staticServePath}"/> <link rel="dns-prefetch" href="//cdn.jsdelivr.net"/> <link rel="preconnect" href="${staticServePath}"> <link rel="icon" type="image/png" href="${faviconURL}"/> <link rel="apple-touch-icon" href="${faviconURL}"> <link rel="shortcut icon" type="image/x-icon" href="${faviconURL}"> <meta name="copyright" content="B3log"/> <meta http-equiv="Window-target" content="_top"/> <meta property="og:locale" content="${langLabel}"/> <meta property="og:title" content="${title}"/> <meta property="og:site_name" content="${blogTitle?html}"/> <meta property="og:url" content="${servePath}${request.requestURI}<#if request.queryString??>?${request.queryString}</#if>"/> <meta property="og:image" content="${faviconURL}"/> <link rel="search" type="application/opensearchdescription+xml" title="${title}" href="/opensearch.xml"> <link href="${servePath}/rss.xml" title="RSS" type="application/rss+xml" rel="alternate"/> <link rel="manifest" href="${servePath}/manifest.json"> <#if paginationCurrentPageNum??> <#if paginationCurrentPageNum == 1> <link rel="canonical" href="${servePath}${request.requestURI}"> <#else> <link rel="canonical" href="${servePath}${request.requestURI}<#if request.queryString??>?${request.queryString}</#if>"> </#if> <#else> <link rel="canonical" href="${servePath}${request.requestURI}"> </#if> <#nested> <#if htmlHead??> ${htmlHead} </#if> </#macro>
\ No newline at end of file \ No newline at end of file
......
...@@ -17,19 +17,16 @@ ...@@ -17,19 +17,16 @@
along with this program. If not, see <https://www.gnu.org/licenses/>. along with this program. If not, see <https://www.gnu.org/licenses/>.
--> -->
<#include "macro-common_head.ftl"/>
<#macro commonPage title> <#macro commonPage title>
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="utf-8"/> <@head title="${title} - ${blogTitle}">
<meta name="viewport" content="initial-scale=1.0,user-scalable=no,maximum-scale=1,width=device-width"> <link type="text/css" rel="stylesheet"
<meta name="viewport" content="initial-scale=1.0,user-scalable=no,maximum-scale=1" media="(device-height: 568px)"> href="${staticServePath}/scss/start.css?${staticResourceVersion}" charset="utf-8"/>
<meta name="robots" content="none"/> <meta name="robots" content="none"/>
<title>${title}<#if blogTitle??> - ${blogTitle}</#if></title> </@head>
<link type="text/css" rel="stylesheet"
href="${staticServePath}/scss/start.css?${staticResourceVersion}" charset="utf-8"/>
<link rel="icon" type="image/png" href="${faviconURL}"/>
<link rel="apple-touch-icon" href="${faviconURL}">
</head> </head>
<body> <body>
<div class="wrap"> <div class="wrap">
......
...@@ -17,17 +17,14 @@ ...@@ -17,17 +17,14 @@
along with this program. If not, see <https://www.gnu.org/licenses/>. along with this program. If not, see <https://www.gnu.org/licenses/>.
--> -->
<#include "macro-common_head.ftl"/>
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="utf-8"/> <@head title="${searchLabel} - ${blogTitle}${searchLabel}">
<meta name="viewport" content="initial-scale=1.0,user-scalable=no,maximum-scale=1,width=device-width"> <link type="text/css" rel="stylesheet"
<meta name="viewport" content="initial-scale=1.0,user-scalable=no,maximum-scale=1" media="(device-height: 568px)"> href="${staticServePath}/scss/start.css?${staticResourceVersion}" charset="utf-8"/>
<title>${searchLabel} - ${blogTitle}${searchLabel}</title> </@head>
<link type="text/css" rel="stylesheet"
href="${staticServePath}/scss/start.css?${staticResourceVersion}" charset="utf-8"/>
<link rel="icon" type="image/png" href="${faviconURL}"/>
<link rel="apple-touch-icon" href="${faviconURL}">
</head> </head>
<body class="search__body"> <body class="search__body">
<div class="search__header fn-clear"> <div class="search__header fn-clear">
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment