Masonry Tiles

Hi,

I am presently using the Masonry Tiles style to display two posts on a page. The problem is that only the title is a link (clickable). How can I make the entire image clickable and not just the title?

Thanks! :)

Comments

  • Hi,

    we are sorry but it it not possible unfortunately.

    Thanks!
  • edited March 2017
    Hmmm, it's maybe too late but it can be useful for others.
    To make the entire image clickable and not just the title :

    - take file "content-post.php" in the folder "includes"
    - after the line "$output .= '<div class="'. $post_class .'" '. $bg_color .'>';" insert this :
    $output .= '<a class="post-click" href="'. get_permalink() .'"></a>';
    - put this new "content-post.php" in your child theme in a new (or not) "includes" folder.
    - in "functions.php" of your child theme : add this :
    require_once( get_stylesheet_directory() .'/includes/content-post.php' );
    - in "style.css" of your child theme add this :
    .post-click { position: absolute; width: 100%; height: 100%; top: 0; left: 0; text-decoration: none; z-index: 10; background-color: white; opacity: 0; }

    Enjoy the trick :)
  • Thanks, I will try that next time! :)
  • Works perfectly! thank you @musiconair
    :)
  • Thanks, great work!
Sign In or Register to comment.