2020-02-18, 02:40 PM
2020-02-18, 04:03 PM
are you using MyBB or other forum system ? above attachment is showing other system.
anyway, there is no easy method to get image from the posted content to use for sharing.
one can simply use og:image tag in the header to send a static image (eg. site logo) to facebook
anyway, there is no easy method to get image from the posted content to use for sharing.
one can simply use og:image tag in the header to send a static image (eg. site logo) to facebook
2020-02-18, 04:39 PM
(2020-02-18, 04:03 PM).m. Wrote: [ -> ]are you using MyBB or other forum system ? above attachment is showing other system.
anyway, there is no easy method to get image from the posted content to use for sharing.
one can simply use og:image tag in the header to send a static image (eg. site logo) to facebook
I just install a new fresh mybb and doing some tests in order the new forum will work fine .
Shall I open the index.php to do this ?
2020-02-18, 04:53 PM
Hello,
you can add the og:image tag as .m. said - you can add it to the headerinclude template.
To do that, go into the ACP (yourforum.tld/admin in most cases), open the Themes & Templates tab, select Themes (on the left sidebar), open your theme, go into Ungrouped Templates, and open headerinclude. There, add <meta property="og:image" content="https://url-to-image.here"/> anywhere outside the <script> tags - so, for example, at the top.
Save, wait a bit for Facebook to register that it's there, and it should work.
you can add the og:image tag as .m. said - you can add it to the headerinclude template.
To do that, go into the ACP (yourforum.tld/admin in most cases), open the Themes & Templates tab, select Themes (on the left sidebar), open your theme, go into Ungrouped Templates, and open headerinclude. There, add <meta property="og:image" content="https://url-to-image.here"/> anywhere outside the <script> tags - so, for example, at the top.
Save, wait a bit for Facebook to register that it's there, and it should work.
2020-02-18, 05:00 PM
see also MyBB Templates guidance
content sharing plugins are also available for facebook & twitter (eg.)
content sharing plugins are also available for facebook & twitter (eg.)
2021-12-10, 11:45 AM
How can I make the meta property for og:image go to the attachments on the thread so I can choose one of those to post with the thread on Facebook? Any help would be appreciated.
2021-12-13, 08:36 PM
I have this on my site, but I created a custom plugin to pull the image as a preview image. the bottom line is, you will need a plugin that pulls the attachment image as a variable like
{$attach['image']}
Then you have to place said variable into
<meta property="og:image" content="{$attach['image']}">
and Wholla, that is what you are looking, but now you need a plugin or come up with a way to pull attach image
{$attach['image']}
Then you have to place said variable into
<meta property="og:image" content="{$attach['image']}">
and Wholla, that is what you are looking, but now you need a plugin or come up with a way to pull attach image
2021-12-14, 09:18 AM
(2021-12-13, 08:36 PM)Michael2014 Wrote: [ -> ]I have this on my site, but I created a custom plugin to pull the image as a preview image. the bottom line is, you will need a plugin that pulls the attachment image as a variable like
{$attach['image']}
Then you have to place said variable into
<meta property="og:image" content="{$attach['image']}">
and Wholla, that is what you are looking, but now you need a plugin or come up with a way to pull attach image
Thank you for the insight. I appreciate it. I'll look into it.