Can't Retrieve Image Attributes
-
Title and Caption aren’t being retrieved. My code used
<?php if( class_exists(‘Dynamic_Featured_Image’) ) {
global $dynamic_featured_image;
$featured_images = $dynamic_featured_image->get_featured_images( );
//print_r($featured_images);//You can now loop through the image to display them as required
foreach($featured_images as $featured_image) {echo ”
- <figure>”;
echo “<div>”;
echo “<img src='”.$featured_image[‘full’].”‘”;
echo “/>”;
echo “</div>”;
echo “<figcaption>”;
echo “<h3>”;
$title = $dynamic_featured_image->get_image_title($featured_image);
$caption = $dynamic_featured_image->get_image_caption($featured_image);
echo “</h3>”;
echo “Enlarge“;
echo “</figcaption>”;
echo “</figure>
“;
}
}
?>The result is nothing at all./.
- <figure>”;
- The topic ‘Can't Retrieve Image Attributes’ is closed to new replies.