diff options
author | Nicolas LÅ“uillet <nicolas@loeuillet.org> | 2016-10-10 15:20:06 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-10-10 15:20:06 +0200 |
commit | 0ff674a9521ee3c659f727ca98a48bd200652f95 (patch) | |
tree | ed9a66821983952e1ec3af09264ceb1c101addc9 | |
parent | 3e761063e2fb334f84bebc2375c2b3e3bfe758eb (diff) | |
parent | 020c723e2865dbf61cca9fb14199ce07f479865a (diff) | |
download | wallabag-0ff674a9521ee3c659f727ca98a48bd200652f95.tar.gz wallabag-0ff674a9521ee3c659f727ca98a48bd200652f95.tar.zst wallabag-0ff674a9521ee3c659f727ca98a48bd200652f95.zip |
Merge pull request #2418 from wallabag/add-twitter-cards
Added support of Twitter Cards for public articles
-rw-r--r-- | src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/share.html.twig | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/share.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/share.html.twig index a0a0d3c3..b50226ef 100644 --- a/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/share.html.twig +++ b/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/share.html.twig | |||
@@ -30,11 +30,15 @@ | |||
30 | <meta property="og:title" content="{{ entry.title | raw }}" /> | 30 | <meta property="og:title" content="{{ entry.title | raw }}" /> |
31 | <meta property="og:type" content="article" /> | 31 | <meta property="og:type" content="article" /> |
32 | <meta property="og:url" content="{{ app.request.uri }}" /> | 32 | <meta property="og:url" content="{{ app.request.uri }}" /> |
33 | {% set picturePath = app.request.schemeAndHttpHost ~ asset('bundles/wallabagcore/themes/_global/img/logo-other_themes.png') %} | ||
33 | {% if entry.previewPicture is not null %} | 34 | {% if entry.previewPicture is not null %} |
34 | <meta property="og:image" content="{{ entry.previewPicture }}" /> | 35 | {% set picturePath = entry.previewPicture %} |
35 | {% else %} | ||
36 | <meta property="og:image" content="{{ app.request.schemeAndHttpHost }}{{ asset('bundles/wallabagcore/themes/_global/img/logo-other_themes.png') }}" /> | ||
37 | {% endif %} | 36 | {% endif %} |
37 | <meta property="og:image" content="{{ picturePath }}" /> | ||
38 | <meta name="twitter:card" content="summary" /> | ||
39 | <meta name="twitter:image" content="{{ picturePath }}" /> | ||
40 | <meta name="twitter:site" content="@wallabagapp" /> | ||
41 | <meta name="twitter:title" content="{{ entry.title | raw }}" /> | ||
38 | </head> | 42 | </head> |
39 | <body> | 43 | <body> |
40 | <header> | 44 | <header> |