Support

Account

Home Forums General Issues Grabbing full image path for use with Get The Image Reply To: Grabbing full image path for use with Get The Image

  • Thanks! I’ve ended up using this in order to still have a fallback image using Get The Image:

    			<?php 	$attachment_id = get_field('product_image');
    				$size = "thumbnail";
    				$image = wp_get_attachment_image_src( $attachment_id, $size ); 	
    				if ( $image != 0 ) { ?>
    				<img src="<?php echo $image[0]; ?>" />
    				
    			<?php 	} else {
    				get_the_image( array( 'size' => 'thumbnail', 'default_image' => get_stylesheet_directory_uri() . '/images/placeholder.jpg' ) );
    			} ?>