After migrating the site to another server…
-
After migrating the site to another server both
$post_id
andget_the_ID()
return empty strings, where the featured images are supposed to show:‘<div class=”entry-thumb”>
<img src=”<?php echo wave_get_post_thumb_url(get_the_ID(), 814, 400); ?>” alt=””/> (renders <img src=”” alt=””>)
<img src=”<?php echo wave_get_post_thumb_url($post_id, 814, 400); ?>” alt=””/> (renders <img src=”” alt=””>)
</div>’The original site works fine in that matter (it is still running previous version of WP, not 4.3)
Any idea where I should look for the solution?
wave_get_post_thumb_url
is a custom function which came from the theme developers, who are out of business now, but it seems to work fine with the public site.
It looks rather simple (I am not a PHP developer, so humor me):function wave_get_post_thumb_url($post_id, $width = 150, $height = 150) { $attachment_id = get_post_thumbnail_id($post_id); return wave_get_thumb_url($attachment_id, $width, $height); }
Any help would be highly apprecciated.
- The topic ‘After migrating the site to another server…’ is closed to new replies.