mirror of
https://github.com/c0de-archive/pelican-mg.git
synced 2024-12-22 16:32:40 +00:00
Stripped tags from descriptions in meta tags, OG_IMAGE now refers to absolute URL
This commit is contained in:
parent
37f9811fa3
commit
08473d33a5
@ -9,8 +9,8 @@
|
|||||||
<meta name="twitter:title" content="{{ article.title|capitalize }}" />
|
<meta name="twitter:title" content="{{ article.title|capitalize }}" />
|
||||||
<meta name="twitter:url" content="{{ SITEURL }}/{{ article.url }}" />
|
<meta name="twitter:url" content="{{ SITEURL }}/{{ article.url }}" />
|
||||||
{% if article.summary %}
|
{% if article.summary %}
|
||||||
<meta property="og:description" content="{{ article.summary }}" />
|
<meta property="og:description" content="{{ article.summary|striptags }}" />
|
||||||
<meta name="twitter:description" content="{{ article.summary }}" />
|
<meta name="twitter:description" content="{{ article.summary|striptags }}" />
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if article.date %}
|
{% if article.date %}
|
||||||
<meta property="og:article:published_time" content="{{ article.date }}">
|
<meta property="og:article:published_time" content="{{ article.date }}">
|
||||||
@ -25,12 +25,12 @@
|
|||||||
<meta property="og:article:tag" content="{{ tag }}">
|
<meta property="og:article:tag" content="{{ tag }}">
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% if article.image %}
|
{% if article.image %}
|
||||||
<meta property="og:image" content="{{ SITEURL }}/static/{{ article.image }}" />
|
<meta property="og:image" content="{{ article.image }}" />
|
||||||
<meta name="twitter:image" content="{{ SITEURL }}/static/{{ article.image }}" />
|
<meta name="twitter:image" content="{{ article.image }}" />
|
||||||
{% elif OG_IMAGE%}
|
{% elif OG_IMAGE %}
|
||||||
<meta property="og:image" content="{{ SITEURL }}/static/{{ OG_IMAGE }}" />
|
<meta property="og:image" content="{{ OG_IMAGE }}" />
|
||||||
<meta property="og:image:type" content="{{ OG_IMAGE_TYPE }}" />
|
<meta property="og:image:type" content="{{ OG_IMAGE_TYPE }}" />
|
||||||
<meta name="twitter:image" content="{{ SITEURL }}/static/{{ OG_IMAGE }}" />
|
<meta name="twitter:image" content="{{ OG_IMAGE }}" />
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
<meta name="author" content="{{ AUTHOR }}">
|
<meta name="author" content="{{ AUTHOR }}">
|
||||||
<meta name="copyright" content="{{ AUTHOR }}">
|
<meta name="copyright" content="{{ AUTHOR }}">
|
||||||
<meta name="twitter:card" content="summary" />
|
<meta name="twitter:card" content="summary" />
|
||||||
<meta name="twitter:site" content="{{ TWITTER_USERNAME }}" />
|
<meta name="twitter:site" content="@{{ TWITTER_USERNAME }}" />
|
||||||
<meta property="og:site_name" content="{{ SITENAME }}" />
|
<meta property="og:site_name" content="{{ SITENAME }}" />
|
||||||
{% block seo %}
|
{% block seo %}
|
||||||
<meta property="og:title" content="{{ SITENAME }}" />
|
<meta property="og:title" content="{{ SITENAME }}" />
|
||||||
@ -25,9 +25,9 @@
|
|||||||
<meta name="twitter:description" content="{{ DESCRIPTION }}" />
|
<meta name="twitter:description" content="{{ DESCRIPTION }}" />
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if OG_IMAGE %}
|
{% if OG_IMAGE %}
|
||||||
<meta property="og:image" content="{{ SITEURL }}/static/{{ OG_IMAGE }}" />
|
<meta property="og:image" content="{{ OG_IMAGE }}" />
|
||||||
<meta property="og:image:type" content="{{ OG_IMAGE_TYPE }}" />
|
<meta property="og:image:type" content="{{ OG_IMAGE_TYPE }}" />
|
||||||
<meta name="twitter:image" content="{{ SITEURL }}/static/{{ OG_IMAGE }}" />
|
<meta name="twitter:image" content="{{ OG_IMAGE }}" />
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
<link href="{{ SITEURL }}/{{ FEED_ALL_ATOM }}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} ATOM Feed"/>
|
<link href="{{ SITEURL }}/{{ FEED_ALL_ATOM }}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} ATOM Feed"/>
|
||||||
|
@ -8,16 +8,16 @@
|
|||||||
<meta property="og:url" content="{{ SITEURL }}/{{ page.url }}" />
|
<meta property="og:url" content="{{ SITEURL }}/{{ page.url }}" />
|
||||||
<meta name="twitter:url" content="{{ SITEURL }}/{{ page.url }}" />
|
<meta name="twitter:url" content="{{ SITEURL }}/{{ page.url }}" />
|
||||||
{% if page.image %}
|
{% if page.image %}
|
||||||
<meta property="og:image" content="{{ SITEURL }}/static/{{ page.image }}" />
|
<meta property="og:image" content="{{ page.image }}" />
|
||||||
<meta name="twitter:image" content="{{ SITEURL }}/static/{{ page.image }}" />
|
<meta name="twitter:image" content="{{ page.image }}" />
|
||||||
{% elif OG_IMAGE %}
|
{% elif OG_IMAGE %}
|
||||||
<meta property="og:image" content="{{ SITEURL }}/static/{{ OG_IMAGE }}" />
|
<meta property="og:image" content="{{ OG_IMAGE }}" />
|
||||||
<meta property="og:image:type" content="{{ OG_IMAGE_TYPE }}" />
|
<meta property="og:image:type" content="{{ OG_IMAGE_TYPE }}" />
|
||||||
<meta name="twitter:image" content="{{ SITEURL }}/static/{{ OG_IMAGE }}" />
|
<meta name="twitter:image" content="{{ OG_IMAGE }}" />
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if page.summary %}
|
{% if page.summary %}
|
||||||
<meta property="og:description" content="{{ page.summary }}" />
|
<meta property="og:description" content="{{ page.summary|striptags }}" />
|
||||||
<meta name="twitter:description" content="{{ page.summary }}" />
|
<meta name="twitter:description" content="{{ page.summary|striptags }}" />
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user