WordPress.org

Ready to get started?Download WordPress

Forums

My Post Order
section_name value is null case (2 posts)

  1. geometron
    Member
    Posted 2 years ago #

    personally, i would prefer if the query_posts returned no posts when the section_name value does not exist, although, i can understand the logic behind returning all posts as is the default.

    is there a way i can test for a specific section_name value before i query_posts? if not, i would like to request this feature be added. something like:

    <?php if( has_section_name('My_Section') ) : query_posts('section_name=My_Section'); ?>
    (the loop)
    <?php else: ?>
    (fail content)
    <?php endif; ?>

    http://wordpress.org/extend/plugins/my-posts-order/

  2. Kapil Chugh
    Member
    Plugin Author

    Posted 2 years ago #

    I have added your suggestion in my TODO list.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.