Title: Shows posts based on key/value
Last modified: August 18, 2016

---

# Shows posts based on key/value

 *  Resolved [pramodd](https://wordpress.org/support/users/pramodd/)
 * (@pramodd)
 * [19 years ago](https://wordpress.org/support/topic/shows-posts-based-on-keyvalue/)
 * Here is my problem:
 * 1] I am showing key/value pairs for each post after
    the post text.
 * Example: Assume that I have a wordpress blog which is
    a job site. Every post
   on the site will contain the job description followed by the Key “Location” to
   display the location of the job.
 * So the key value is shown as:
 * Location: London | Paris | California
 * 2] I want the above values [London, Paris, California
    ] to be shown as a hyperlink.
   When I click on the London hyperlink it should show me all posts [job openings]
   in London. If I click on Paris it should show me all posts [job openings] in 
   Paris and so on.
 * Is there a plugin to do this? If NOT how do I implement this feature using custom
   SQL query?
 * Any help will be deeply appreciated.

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

 *  [MichaelH](https://wordpress.org/support/users/michaelh/)
 * (@michaelh)
 * [19 years ago](https://wordpress.org/support/topic/shows-posts-based-on-keyvalue/#post-567925)
 * Couldn’t you use tags (Ultimate Tag Warrior plugin) or even Categories for that
   instead of Custom Fields?
 *  [Doodlebee](https://wordpress.org/support/users/doodlebee/)
 * (@doodlebee)
 * [19 years ago](https://wordpress.org/support/topic/shows-posts-based-on-keyvalue/#post-567926)
 * Can you not just use category setups? Like, when you wrote a post, just be sure
   to add the category for whatever city you want it to be in. Then it’ll appear
   in all (as long as you keep it in “Uncategorized” – or whatever your default 
   post category is in) *and* in whatever city you want.
 *  Thread Starter [pramodd](https://wordpress.org/support/users/pramodd/)
 * (@pramodd)
 * [19 years ago](https://wordpress.org/support/topic/shows-posts-based-on-keyvalue/#post-567965)
 * Category is already displayed before key/value pair.
 * This is how the post looks:
 * Post Title
    Post Body Posted in Developer, Customer Services | Location: UK, 
   USA
 * Clicking on the category name [i.e. Developer or Customer Services] shows list
   of posts within that category.
 * I want to show list of posts by location. If a user clicks on UK it should show
   all posts for UK & if he clicks on USA it should show all posts [in this case
   jobs] for USA and so on.
 * I hope I was able to explain properly.
 *  [moshu](https://wordpress.org/support/users/moshu/)
 * (@moshu)
 * [19 years ago](https://wordpress.org/support/topic/shows-posts-based-on-keyvalue/#post-567977)
 * Please, don’t double post – duplicate posts get deleted without warning!
 *  Moderator [Samuel Wood (Otto)](https://wordpress.org/support/users/otto42/)
 * (@otto42)
 * WordPress.org Admin
 * [19 years ago](https://wordpress.org/support/topic/shows-posts-based-on-keyvalue/#post-567984)
 * You should try using Tags instead of custom fields for this. Tags will do what
   you want almost automatically.
 * Try Ultimate Tag Warrior.
 *  Thread Starter [pramodd](https://wordpress.org/support/users/pramodd/)
 * (@pramodd)
 * [19 years ago](https://wordpress.org/support/topic/shows-posts-based-on-keyvalue/#post-567988)
 * Can you tell me how to use Ultimate Tag Warrior for this purpose?
 *  [moshu](https://wordpress.org/support/users/moshu/)
 * (@moshu)
 * [19 years ago](https://wordpress.org/support/topic/shows-posts-based-on-keyvalue/#post-567991)
 * First download, install it… and you’ll realize: you can “tag” your posts with
   UK or US for example, and those tags will become clickable links when displayed.
 *  Thread Starter [pramodd](https://wordpress.org/support/users/pramodd/)
 * (@pramodd)
 * [19 years ago](https://wordpress.org/support/topic/shows-posts-based-on-keyvalue/#post-567999)
 * Thanks!!! It worked.

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

The topic ‘Shows posts based on key/value’ is closed to new replies.

## Tags

 * [custom](https://wordpress.org/support/topic-tag/custom/)
 * [key](https://wordpress.org/support/topic-tag/key/)
 * [using](https://wordpress.org/support/topic-tag/using/)
 * [value](https://wordpress.org/support/topic-tag/value/)

 * 8 replies
 * 5 participants
 * Last reply from: [pramodd](https://wordpress.org/support/users/pramodd/)
 * Last activity: [19 years ago](https://wordpress.org/support/topic/shows-posts-based-on-keyvalue/#post-567999)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
