Forums

[resolved] Link to custom field query (3 posts)

  1. everten2
    Member
    Posted 2 years ago #

    I have posts with a custom field "beer_type". Now let's say I want to have a link on my main page that goes to a page which only displays posts where beer_type=lager.

    I know that I can display just these posts by doing the follwing:
    <?php query_posts('meta_key=beer_type&meta_value=lager'); ?>

    But how would I create a link to a page that only displays these results?

    I would like to automatically generate these links because there will be several beer_type values which will be continually updated.

    Thanks in advanced.

    Jeff

  2. MichaelH
    Volunteer
    Posted 2 years ago #

  3. everten2
    Member
    Posted 2 years ago #

    Nice. This is just what I needed. Thanks.

Topic Closed

This topic has been closed to new replies.

About this Topic