Title: Selective next/prev_post_link &#8211; Coder highly needed!
Last modified: August 18, 2016

---

# Selective next/prev_post_link – Coder highly needed!

 *  [barmin](https://wordpress.org/support/users/barmin/)
 * (@barmin)
 * [19 years, 4 months ago](https://wordpress.org/support/topic/selective-nextprev_post_link-coder-highly-needed/)
 * I need someone to write a script/hack for me, please.
 * If I’ve got a post within 2 categories, I need to be able to tell next_post_link()
   tag from which category to pick.
 * I’ve been looking through the template-funcions-links.php, but I really wouldn’t
   know what to do.
 * ExcludedCategories parameter doesn’t help, please don’t suggest it.

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

 *  Thread Starter [barmin](https://wordpress.org/support/users/barmin/)
 * (@barmin)
 * [19 years, 4 months ago](https://wordpress.org/support/topic/selective-nextprev_post_link-coder-highly-needed/#post-515045)
 * I got it conceptualized. It should be like this:
 * function next_post_by_cat($cat_id = ”) {
 * > get.category($cat).posts
    > get.current.post.date > select.next.post.by.date
 * output
 * }
 * Easy, ain’t it?
 *  [Chris_K](https://wordpress.org/support/users/handysolo/)
 * (@handysolo)
 * [19 years, 4 months ago](https://wordpress.org/support/topic/selective-nextprev_post_link-coder-highly-needed/#post-515059)
 * Stick to one thread please.
    [http://wordpress.org/support/topic/103638?replies=3](http://wordpress.org/support/topic/103638?replies=3)

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

The topic ‘Selective next/prev_post_link – Coder highly needed!’ is closed to new
replies.

## Tags

 * [categories](https://wordpress.org/support/topic-tag/categories/)
 * [next](https://wordpress.org/support/topic-tag/next/)
 * [previous](https://wordpress.org/support/topic-tag/previous/)
 * [specific](https://wordpress.org/support/topic-tag/specific/)
 * [tag](https://wordpress.org/support/topic-tag/tag/)

 * 2 replies
 * 2 participants
 * Last reply from: [Chris_K](https://wordpress.org/support/users/handysolo/)
 * Last activity: [19 years, 4 months ago](https://wordpress.org/support/topic/selective-nextprev_post_link-coder-highly-needed/#post-515059)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
