Include value of custom field in query_posts
-
I am not sure if this can be done but am hopeful it can be ??
I am working on a very complicated layout using multiple custom post types and taxonomies. I need to create many different templates so only certain posts are displayed on certain pages. My thinking was I could use one template and then use custom fields to popular the query_posts info.
What I am trying to do (with no success thus far) is the following
- Create a page called Goalie
- Create a page template called Drills
- On the page Goalie, add a custom field titled age-group with a value of 6
- In the page template, use query_posts. I want to be able to take the age-group=6 and add it to the query post automatically.
- This way I can create multiple pages like Goalie (ex. Dribbling, Agility, etc) assign them all the page template of Drills and popular the query_posts on the drills template by using the custom field
The actual layout and coding will be more complex than that (much more!) but I wanted to simplify it for this question. So is there anyway to assign a value to a query_post from a custom field on a page?
I hope I made sense with this ??
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Include value of custom field in query_posts’ is closed to new replies.