• Hi guys,

    Is it possible to have the first image in the post (the one before the MORE tag) link to the full post, just like the post title or the ‘Read more’ link do? I know I can wrap the image in once posted, but this way it remains a link even after opening the full version of the post, whereas the post title is no longer clickable.

    You can see the sample posts here: https://www.minimalismi.com

    Thanks in advance,

    White

Viewing 1 replies (of 1 total)
  • If you just want the image to link to the single post:
    When you’re uploading the image and are on the “Add an Image” popup menu and choosing the settings, find “Link URL.” Underneath that, click the “Post URL” button.

    But it sounds like you want the image to link to the post on the homepage, and then on the single post page have the image link to a larger version of itself? I’m sure there’s a better way to do this, but you could enable thumbnails and have the homepage image be just that, and set the thumbnail size to be 460 x 307 (like the images on your homepage). Make the thumbnail image link to the post page URL by setting it up like this in your index.php file:
    <a href=" <?php the_permalink(); ?>" title="Permanent link to <?php the_title_attribute(); ?>"><?php the_post_thumbnail(); ?></a>

    Then, if you want to make the single post page’s image link to a larger version of the image:
    When you’re at the “Add an Image” popup menu, make sure the link URL is set to “Link to Image.” After you’ve clicked “use as thumbnail”, click “insert into post”. That should do it!

    Here are some good instructions to enabling post thumbnails in your theme:
    https://www.kremalicious.com/2009/12/wordpress-post-thumbnails/
    https://markjaquith.wordpress.com/2009/12/23/new-in-wordpress-2-9-post-thumbnail-images/

    Hope that helps!

Viewing 1 replies (of 1 total)
  • The topic ‘Lead image as MORE tag or post title link’ is closed to new replies.