jekyll-seo-tag/lib/template.html

119 lines
3.8 KiB
HTML
Raw Normal View History

2016-02-20 19:26:06 +00:00
<!-- Begin Jekyll SEO tag v{{ seo_tag.version }} -->
2017-04-06 23:02:32 +00:00
{% if seo_tag.title? %}
<title>{{ seo_tag.title }}</title>
2016-02-23 02:31:59 +00:00
{% endif %}
<meta name="generator" content="Jekyll v{{ jekyll.version }}" />
2017-09-05 21:10:26 +00:00
2017-04-06 23:02:32 +00:00
{% if seo_tag.page_title %}
<meta property="og:title" content="{{ seo_tag.page_title }}" />
2015-10-25 21:21:46 +00:00
{% endif %}
2016-02-09 23:33:53 +00:00
2017-04-06 23:02:32 +00:00
{% if seo_tag.author.name %}
<meta name="author" content="{{ seo_tag.author.name }}" />
{% endif %}
2016-02-09 23:33:53 +00:00
<meta property="og:locale" content="{{ seo_tag.page_locale }}" />
2015-10-25 21:21:46 +00:00
2017-04-06 23:02:32 +00:00
{% if seo_tag.description %}
<meta name="description" content="{{ seo_tag.description }}" />
<meta property="og:description" content="{{ seo_tag.description }}" />
2015-10-25 21:21:46 +00:00
{% endif %}
2017-04-06 23:02:32 +00:00
{% if site.url %}
2017-04-08 18:20:21 +00:00
<link rel="canonical" href="{{ seo_tag.canonical_url }}" />
<meta property="og:url" content="{{ seo_tag.canonical_url }}" />
2015-10-25 21:21:46 +00:00
{% endif %}
2017-04-06 23:02:32 +00:00
{% if seo_tag.site_title %}
<meta property="og:site_name" content="{{ seo_tag.site_title }}" />
2015-10-25 21:21:46 +00:00
{% endif %}
2017-04-06 23:02:32 +00:00
{% if seo_tag.image %}
<meta property="og:image" content="{{ seo_tag.image.path }}" />
{% if seo_tag.image.height %}
<meta property="og:image:height" content="{{ seo_tag.image.height }}" />
2017-02-16 19:07:35 +00:00
{% endif %}
2017-04-06 23:02:32 +00:00
{% if seo_tag.image.width %}
<meta property="og:image:width" content="{{ seo_tag.image.width }}" />
2016-04-19 13:55:34 +00:00
{% endif %}
{% endif %}
2015-10-25 21:21:46 +00:00
{% if page.date %}
<meta property="og:type" content="article" />
2016-02-03 17:52:46 +00:00
<meta property="article:published_time" content="{{ page.date | date_to_xmlschema }}" />
{% else %}
<meta property="og:type" content="website" />
{% endif %}
2016-02-03 17:52:46 +00:00
{% if paginator.previous_page %}
<link rel="prev" href="{{ paginator.previous_page_path | absolute_url }}" />
{% endif %}
{% if paginator.next_page %}
<link rel="next" href="{{ paginator.next_page_path | absolute_url }}" />
2015-10-25 21:21:46 +00:00
{% endif %}
2016-03-05 20:19:14 +00:00
{% if seo_tag.image %}
<meta name="twitter:card" content="{{ page.twitter.card | default: site.twitter.card | default: "summary_large_image" }}" />
<meta property="twitter:image" content="{{ seo_tag.image.path }}" />
{% else %}
<meta name="twitter:card" content="summary" />
{% endif %}
{% if seo_tag.page_title %}
<meta property="twitter:title" content="{{ seo_tag.page_title }}" />
{% endif %}
{% if site.twitter %}
<meta name="twitter:site" content="@{{ site.twitter.username | remove:'@' }}" />
2016-02-09 23:33:53 +00:00
2017-04-06 23:02:32 +00:00
{% if seo_tag.author.twitter %}
<meta name="twitter:creator" content="@{{ seo_tag.author.twitter | remove:'@' }}" />
2015-10-25 21:21:46 +00:00
{% endif %}
{% endif %}
2016-02-03 17:52:46 +00:00
{% if site.facebook %}
{% if site.facebook.admins %}
<meta property="fb:admins" content="{{ site.facebook.admins }}" />
{% endif %}
{% if site.facebook.publisher %}
<meta property="article:publisher" content="{{ site.facebook.publisher }}" />
{% endif %}
{% if site.facebook.app_id %}
<meta property="fb:app_id" content="{{ site.facebook.app_id }}" />
{% endif %}
2016-02-09 23:33:53 +00:00
{% endif %}
2016-02-09 21:22:28 +00:00
2017-01-13 04:37:53 +00:00
{% if site.webmaster_verifications %}
{% if site.webmaster_verifications.google %}
<meta name="google-site-verification" content="{{ site.webmaster_verifications.google }}" />
2017-01-13 04:37:53 +00:00
{% endif %}
2017-04-06 23:02:32 +00:00
2017-01-13 04:37:53 +00:00
{% if site.webmaster_verifications.bing %}
<meta name="msvalidate.01" content="{{ site.webmaster_verifications.bing }}" />
2017-01-13 04:37:53 +00:00
{% endif %}
2017-04-06 23:02:32 +00:00
2017-01-13 04:37:53 +00:00
{% if site.webmaster_verifications.alexa %}
<meta name="alexaVerifyID" content="{{ site.webmaster_verifications.alexa }}" />
2017-01-13 04:37:53 +00:00
{% endif %}
2017-04-06 23:02:32 +00:00
2017-01-13 04:37:53 +00:00
{% if site.webmaster_verifications.yandex %}
<meta name="yandex-verification" content="{{ site.webmaster_verifications.yandex }}" />
2017-01-13 04:37:53 +00:00
{% endif %}
{% if site.webmaster_verifications.baidu %}
<meta name="baidu-site-verification" content="{{ site.webmaster_verifications.baidu }}" />
{% endif %}
2017-01-13 04:37:53 +00:00
{% elsif site.google_site_verification %}
2016-02-09 21:22:28 +00:00
<meta name="google-site-verification" content="{{ site.google_site_verification }}" />
2016-02-03 17:41:05 +00:00
{% endif %}
2017-01-13 04:37:53 +00:00
2016-02-22 18:35:55 +00:00
<script type="application/ld+json">
2017-04-08 18:20:21 +00:00
{{ seo_tag.json_ld | jsonify }}
2016-02-22 18:35:55 +00:00
</script>
2015-10-25 21:21:46 +00:00
<!-- End Jekyll SEO tag -->