Skip to content

Commit

Permalink
Sharing fedoralovespython on social media
Browse files Browse the repository at this point in the history
Enable pretty Twitter and FB formatting.

Add new image for sharing (fedoralovespython-share.jpg)

only JPEG images are allowed
Add metadata for FB and twitter

validated with https://cards-dev.twitter.com/validator (Twitter) and
https://developers.facebook.com/tools/debug/og/object/
Facebook validator shows some warnings which can be ignored:

http://stackoverflow.com/questions/16475336/open-graph-twitter-cards-html5-incompatible

Related issue: fedora-python#25
  • Loading branch information
nmilosev committed Feb 22, 2017
1 parent 970ac4f commit 4e64a2f
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
Binary file added static/img/fedoralovespython-share.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 10 additions & 0 deletions templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,16 @@
<link href="{{ url_for('static', filename='style.css') }}" rel="stylesheet">
<link href="{{ url_for('static', filename='favicon.ico') }}" rel="shortcut icon" type="image/x-icon">
<link href='https://fonts.googleapis.com/css?family=Open+Sans:400,400italic,600,600italic&amp;subset=latin' rel='stylesheet' type='text/css'>
<!-- For Facebook and Twitter: -->
<meta property="og:type" content="article">
<meta property="og:title" content="Fedora Loves Python - fedoralovespython.org">
<meta property="og:description" content="Fedora’s relationship with Python is very close, making it probably the best platform for developing with Python - learn why!">
<meta property="og:url" content="https://fedoralovespython.org/">
<meta property="og:image" content="{{ url_for('static', filename='img/fedoralovespython-share.jpg', _external=True) }}">
<!-- Additionaly, for Twitter: -->
<meta property="twitter:card" content="summary_large_image">
<meta property="twitter:site" content="@fedora">
<meta property="twitter:creator" content="@fedora" />
</head>
<body>
<header>
Expand Down

0 comments on commit 4e64a2f

Please sign in to comment.