This topic contains a post which is marked as Best Answer. Press here if you would like to see it.
*

questions

  • *****
  • 323 posts
Dear all,

In Osclass, where and how can I set a default Open Graph (OG) image - the one with recommended size 1200x630px - so that when my website is shared on Facebook, WhatsApp, or other social media platforms, the same default image appears if a page has no featured image?

For reference, I have also included an image from Google Images.

Thank you,
« Last Edit: September 09, 2025, 07:31:08 AM by questions »

*

MB Themes

@questions
You can add such meta tag in head.php referencing image with required dimension.
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

questions

  • *****
  • 323 posts
@MB
Thank you for your reply

Could you please share a short example of how to add the OG default image in head.php?

I am wondering... is there maybe a plugin that already handles Open Graph tags automatically? Or some OsClass functionality that already does this?

Best,

Marked as best answer by questions on September 17, 2025, 02:54:46 PM
*

MB Themes

Try this:

Code: [Select]
<meta property="og:image" content="https://osclasspoint.com/img/hero-banner-og.jpg" />
<meta property="og:image:width" content="1200" />
<meta property="og:image:height" content="630" />
<meta property="og:image:alt" content="Premium Osclass themes and plugins for your classifieds site" />
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

questions

  • *****
  • 323 posts
Try this:

Code: [Select]
<meta property="og:image" content="https://osclasspoint.com/img/hero-banner-og.jpg" />
<meta property="og:image:width" content="1200" />
<meta property="og:image:height" content="630" />
<meta property="og:image:alt" content="Premium Osclass themes and plugins for your classifieds site" />

Finally I see that it is not working. The current logo is chosen by default from here: /oc-content/themes/epsilon/images/logo.png

Is there any way to replace it manually?

Thanks,
« Last Edit: September 17, 2025, 03:19:21 PM by questions »

*

MB Themes

Check head.php in theme folder
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

questions

  • *****
  • 323 posts
Check head.php in theme folder

I wasn’t able to manage it.
Would it be possible for you to add an og:image field somewhere in the Osclass settings (for the homepage only)? Everything else works fine for the items.

Best regards,

*

MB Themes

Osclass use oc-includes/osclass/structured_data.php for structured data.
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots