Hello @specstanza,
Thanks for reporting this, and sorry for the trouble!
From what you’re saying, it does sound indeed like a theme conflict.
Have you tried to temporary switch to a default theme by keeping Jetpack installed, to see if the issue persists? I see that your site is under maintenance so I cannot dig into it much.
Let me know what you find out, and we’ll take it from there if we can. Thanks!
Hi @erania-pinnera !
Thank you for your reply. 🙂
It does seem to work by switching theme (TwentyTwentyOne) and get_the_post_thumbnail on index.php page.
I forgot to mention that – with my theme – get_the_post_thumbnail works when on single.php page.
I did read everything I could about templates hierarchy but it doesn’t solve my issue for my front-page.php.
You are right : this is not easy for you to help when my website is in Maintenance Mode. In case it’s relevant, here is my template ‘hierarchy’ and news.php code (which is pretty basic) :
- front-page.php : get_template_part(‘/home/news’)
- /home/news.php contains the following php code :
<?php
/**
* The template for displaying posts
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/#single-post
*
* @package MyCustomTheme
*/
?>
<ul id="slider-id" class="slider-class">
<?php
$recent_posts = wp_get_recent_posts(array(
'numberposts' => 4, // Number of recent posts thumbnails to display
'post_status' => 'publish' // Show only the published posts
));
foreach( $recent_posts as $post_item ) : ?>
<li>
<a href="<?php echo get_permalink($post_item['ID']) ?>">
<?php get_the_post_thumbnail($post_item['ID'], 'full');
/* As mentionned in first post, I've tried several method to retrieve post_thumbnails when calling latest posts */ ?>
<p class="slider-caption-class"><?php echo $post_item['post_title'] ?></p>
</a>
</li>
<?php endforeach; ?>
</ul>
Thank you for your attention on my issue,
UPDATE
Just find a line in my template functions.php :
/**
* Load Jetpack compatibility file.
*/
require get_template_directory() . '/inc/jetpack.php';
When commented, page content returns Fatal Error :
carlistings_get_featured_posts() in /home/wp-content/themes/carlistings/template-parts/featured-content.php
So I guess the ‘base’ template (CarListings) can indeed work with JetPack plugin.
-
This reply was modified 4 years, 3 months ago by
specstanza.
-
This reply was modified 4 years, 3 months ago by
specstanza.
Hi @specstanza –
It does sound like this is an issue with the theme and/or your child theme. If you try using just the “CarListings” theme, does it work without an issue? You could test that to confirm it works with Jetpack.
In any case, it’s outside our scope of support to offer assistance on theme modifications. You might try the general WordPress forms as this doesn’t appear related to Jetpack.
Hi @lastsplash – many thanks for your suggestions
If you try using just the “CarListings” theme, does it work without an issue? You could test that to confirm it works with Jetpack.
I’ve installed the CarListings theme and having the exact same issue.
You might try the general WordPress forms as this doesn’t appear related to Jetpack.
I’m sorry but I strongly disagree: this happens when Jetpack is active – so it does seem related to me.
UPDATE – RESOLVED
– new Childtheme
– new plugin Health Check & Troubleshooting
– returned something was missing (imagick)
– setup hosting-side .php settings to unable imagick
– found this post
– tried code on .index.php + .home.php + front-page.php
– “Customize” (upper admin bar) > Content options > De-ticked and re-ticked everything for full post or post excepert.
Thank you for your support! Hope this will help other users!
-
This reply was modified 4 years, 3 months ago by
specstanza.