Followup after some debugging:
in function my_calendar_draw_event (file my-calendar-output.php)
$event->event_image has image url
while
$data=mc_create_tags($event);
has no relevant image dat, even if post has a featured image
mc_create_tags calls mc_filter_image_data using a filter, so function
mc_image_data($e,$event)
fails to return any image data.
What happens, probably is that a block of code is not executed
if ( isset( $event->event_post ) && is_numeric( $event->event_post ) && get_post_status( $event->event_post ) ) {
get image data from post (FAILS: NO DATA RETURNED)
}
else{
get image data from event (NEVER ENTER HERE ?)
}
I still have no idea why all image info taken pfrom the post are empty even if featured image is there
["full"]=> string(0) "" ["thumbnail"]=> string(0) "" ["thumbnail_url"]=> NULL ["medium"]=> string(0) "" ["medium_url"]=> NULL ["large"]=> string(0) "" ["large_url"]=> NULL ["post-thumbnail"]=> string(0) "" ["post-thumbnail_url"]=> NULL ["image_url"]=> string(0) "" ["image"]=> string(0) ""
What it sounds like to me is that the event post exists, but the featured image is not attached to the event post. That could be because of a migration issue – it’s hard to say. I’d have to see inside your installation to really be able to tell.
I’ll add an additional check to that which verifies whether or not there’s a featured image attached to the post in question, so that fallback will work.
Thank you very much Joe,
as a momentaneus hack, in function mc_image_data(), right before returning the image data I copied the code that never gets executed
$e['image_url'] = ( $event->event_image != '' ) ? $event->event_image : '';
$e['image'] = ( $event->event_image != '' ) ? "<img src='$event->event_image' alt='' class='mc-image' />" : '';
but of course this does not really solve the problem.
I will upgrade my calendar as soon as next version is out. I hope the information I was able to provide will help you if someone else has the same problem.
Thank you again
Michele
Joe, I confirm problem got fixed after upgrading to 2.4.9
Thank you very much
Michele