WordPress.org

Support

Support » How-To and Troubleshooting » How to target the latest Post entry via <a href=”” >

How to target the latest Post entry via <a href=”” >

  • Hi there,

    I’m pretty new to WP and am trying to figure out the following:

    I’ve set by default homepage to be a static Page via the “Reading Settings”
    How do I then target the latest post entry via a <a href ?
    I’ve tried the <?php echo get_permalink(); ?> method but this just target the default page i.e. the static Page.
    I can target a specific post using the ID within the string such as:
    <?php echo get_permalink(1); ?> but this doesn’t really solve the problem as I want the link to target the latest entry.

    Maybe I’m missing something quite obvious here but any direction would be much appreciated

    Thanks in advance
    nickmerr

Viewing 3 replies - 1 through 3 (of 3 total)

No, it is NOT a “problem” by itself. The problem always is that people want to do things that they don’t have the skills for – so we write tutorials for them 🙂

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘How to target the latest Post entry via <a href=”” >’ is closed to new replies.