Is it possible to make the images in the Featured Slider work as links?

We'd like to link the images in the Featured Slider on the home page to their associated posts.

Is this possible?

  • DavidM

    Hello pallaisa,

    I'm going to ask one of the theme developers to provide some insight (in particular, how to do this most efficiently) on this but I found that the following links the featured image to the post.

    On line 442 of the theme's functions.php you'll see the following:

    <img title="<h1><?php the_title(); ?></h1>" alt="" src="<?php bloginfo('template_directory'); ?>/_inc/images/no-images.jpg">
    <?php } else {  ?>
    <img title="<h1><?php the_title(); ?></h1>" alt="" src="<?php echo $get_post_attachment; ?>">

    You can simply replace all of that with the following snippet:

    <a href="<?php echo the_permalink(); ?>"><img title="<h1><?php the_title(); ?></h1>" alt="" src="<?php bloginfo('template_directory'); ?>/_inc/images/no-images.jpg"><a/>
    <?php } else {  ?>
    <a href="<?php echo the_permalink(); ?>"><img title="<h1><?php the_title(); ?></h1>" alt="" src="<?php echo $get_post_attachment; ?>"></a>

    And all this is essentially doing is placing a link to the relevant blog post before the featured image code. Please let me know if you have any trouble with this and I'll see what I can do to assist.

    Cheers,
    David

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.