No Og:image In Magnin-template - Question | JoomShaper

No Og:image In Magnin-template

R

RaBauKi

Template 4 months ago

Hi, I have the following problem: The OG:Image field (and other OG fields) are not generated in the article view (Blog) with the Magnin template.

I am using Joomla 4.0.5 under php 7.4 with the Magnin 1.0.0 template and Pagebuilder 3.8.3 Pro.

To comprehend: Install Magnin Quickstart Jomla 4.0. Activate Open Graph in the template options under BLOG. Insert a featured image in a new Joomla article under Blog Options. Then call up the blog view and then this article there: There is no OG:image field in the article (nor any other Open Graph fields either).

Help is desired, otherwise you can't share posts on facebook in an appealing way.

0
7 Answers
Toufiq
Toufiq
Accepted Answer
Senior Staff 4 months ago

Hi there,

Thanks for contacting us. Sorry for the inconvenience. Will you please provide me the Joomla administrator access to check the issue? I will check & get back to you soon. 

Or follow this process

Go to the file location

templates/magnin/html/com_content/article/default.php

And add this code line on after 62

<?php if($article_format == 'gallery') : ?>
        <?php echo LayoutHelper::render('joomla.content.blog.gallery', array('attribs' => $attribs, 'id'=>$this->item->id)); ?>
    <?php elseif($article_format == 'video') : ?>
        <?php echo LayoutHelper::render('joomla.content.blog.video', array('attribs' => $attribs)); ?>
    <?php elseif($article_format == 'audio') : ?>
        <?php echo LayoutHelper::render('joomla.content.blog.audio', array('attribs' => $attribs)); ?>
    <?php else: ?>
        <?php echo LayoutHelper::render('joomla.content.full_image', $this->item); ?>
    <?php endif; ?>

Add this css code inside the custom.css file.

.article-full-image {
    display: none;
}

-Thanks

0
R
RaBauKi
Accepted Answer
4 months ago

Thanks, it works now. Added the change via an override and the OG:tags are now displayed.

0
Toufiq
Toufiq
Accepted Answer
Senior Staff 4 months ago

You are most welcome. Will you please spend some to write a review about our product and support quality? 

https://extensions.joomla.org/extension/sp-page-builder/

0
R
RaBauKi
Accepted Answer
2 months ago

Dear support team,

this option works, but 2 different images are loaded each time a page is called up. Since the images are very large, there is a large unnecessary data transfer (because one of the images is not used and displayed).

  1. Is there a better, more data-efficient option?
  2. Was the error also reported to the developers and will a corresponding error solution be integrated into an update of the Magnin template?

Best regards

0
Toufiq
Toufiq
Accepted Answer
Senior Staff 2 months ago

Can you share a screencast video about the full scenario? It would be helpful to understand the issue. Thanks

0
R
RaBauKi
Accepted Answer
2 months ago
  1. Please call up the page from the hidden area, here using the current Firefox as an example

  2. Call network analysis (Ctrl-Shift-E) and reload the page.

  3. The image "/images/2022/01/16/rabauki-062_large.jpg" and "/images/2022/01/16/rabauki-062_large.jpg" are loaded. One is the cropped version from the template blog settings, the other is pasted by the code above.

  4. Check the Codeinspector (Ctrl-Shift-C) classes: "article-full-image" and "article-details-top-wrapper".

  5. Both images are almost identical, only one should be loaded. nevertheless, an OG:image field should be output.

Best regards

0
Toufiq
Toufiq
Accepted Answer
Senior Staff 2 months ago

Helix Blog option image generated 4 type of image. You can select details article image from helix blog option.

Screenshot at Mar 01 14-13-53.png

But, header image loaded for the design purpose.

Current og image

https://test7654.rabauki.de/images/2022/01/16/rabauki-062_large.jpg

0