Sharing to Social Media
Currently when sharing any forum post to a social media site like Facebook, no opengraph info is shown or pulled. Is this by design? Can we force meta info?
- KajMagnus @KajMagnus2018-08-22 12:12:08.871Z
Am I understanding correctly, that you want to add OpenGraph related tags to the
<html><head>
?You can add head tags, by adding
<head>...</head>
to the very top of a Talkyard page, example:<head> <title>Page title</title> <meta name="description" content="Page description ..."> <meta property="og:title" content="Page title" /> </head> And here goes the page text, as usual. This'll be inserted into the correct <body><div ...><div...><article><div ...> tag.
Only certain tags are considered, namely
<title>
and<meta>
, and only some attributes, namelyproperty
,content
andname
— and that's all that's needed, for OpenGraph?(Note to self: Here's the code: https://github.com/debiki/talkyard/blob/e58e..../app/debiki/ReactJson.scala#L1102)
You'd do this "manually" (i.e. type
<head><meta ...>
) for each page. Is that an okay approach? Or would you prefer something more automatic somehow, and how would that work and what would it do :- )- CCody @codywarmbo
It would be nice if when sharing a forum topic the title of that topic is used for the og:title and the author of the topic is listed as well.