Support » Requests and Feedback » previous_post and next_post needs to handle blank titles better

  • On my navigation bar, I use the titles of the entries as links to previous/next posts, using the built in tags previous_post and next_post to build the links. However some of my entries have no title, so the links disappear completely. There doesn’t appear to be any easy way in WordPress to handle this situation. I propose that there be a new parameter added to the tag which gives the text to use when the title field is empty. For instance, someone can type <?php previous_post('&laquo; &laquo; %', '', 'yes', 'Untitled Entry'); ?> and a link that looks like this will appear:

    « « Previous Post Title
    « « Untitled Entry

  • The topic ‘previous_post and next_post needs to handle blank titles better’ is closed to new replies.