Hey folks,
I’m looking to externally link the Featured Images of posts that have a custom field (‘external_url’). I’ve created a function (external_link) that captures just this URL and it’s working great with the Post Titles… but I can’t figure out where the Featured Image URL is coming from.
My best guess-timation is that it’s in Framework - Functions - Frontend - Featured.php? I’ve got the Child Theme, etc., running. Here’s my code:
switch ( is_singular() ) {
case true:
printf( '<div class="entry-thumb">%s</div>', $thumb );
break;
case false:
printf( '<?php external_link(); ?>%3$s</a>', // this is where I think I need it?
esc_url( get_permalink() ),
esc_attr( sprintf( __( 'Permalink to: "%s"', '__x__' ), the_title_attribute( 'echo=0' ) ) ),
$thumb
);
break;
}