Title: jv.interaction's Replies | WordPress.org

---

# jv.interaction

  [  ](https://wordpress.org/support/users/jvinteraction/)

 *   [Profile](https://wordpress.org/support/users/jvinteraction/)
 *   [Topics Started](https://wordpress.org/support/users/jvinteraction/topics/)
 *   [Replies Created](https://wordpress.org/support/users/jvinteraction/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/jvinteraction/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/jvinteraction/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/jvinteraction/engagements/)
 *   [Favorites](https://wordpress.org/support/users/jvinteraction/favorites/)

 Search replies:

## Forum Replies Created

Viewing 1 replies (of 1 total)

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Simple Custom Post Order] Seems to break previous_post_link()/next_post_link()…](https://wordpress.org/support/topic/seems-to-break-previous_post_linknext_post_link/)
 *  [jv.interaction](https://wordpress.org/support/users/jvinteraction/)
 * (@jvinteraction)
 * [10 years, 12 months ago](https://wordpress.org/support/topic/seems-to-break-previous_post_linknext_post_link/#post-6571577)
 * I found the trouble with this. It has to do with the scporder_next_post_where
   and the scporder_previous_post_where.
 * In deed, in this function, you overwrite the WHERE condition for the sql so that
   the $in_same_term variable doesn’t work anymore.
 * A quick fix would be to replace in the _scporder\_next\_post\_where_ function:
 * `$where = "WHERE p.menu_order > '" . $current_menu_order . "' AND p.post_type
   = '" . $post->post_type . "' AND p.post_status = 'publish'";`
 * with that :
 * `$where .= " AND p.menu_order < '" . $current_menu_order . "' AND p.post_type
   = '" . $post->post_type . "' AND p.post_status = 'publish'";`
 * and for the _scporder\_previous\_post\_where_ function :
 * `$where = "WHERE p.menu_order > '" . $current_menu_order . "' AND p.post_type
   = '" . $post->post_type . "' AND p.post_status = 'publish'";`
 * with this :
 * `$where .= " AND p.menu_order > '" . $current_menu_order . "' AND p.post_type
   = '" . $post->post_type . "' AND p.post_status = 'publish'";`
 * Please fix this ASAP.

Viewing 1 replies (of 1 total)