Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
  • #23440

    Hey there,

    I really love the prev/next feature on the portfolio items (navigation on the left and right of portfolio item). However, I was wondering if it’s possible to limit them to be Category specific?

    For example, I have portfolio categories of Desktop Wallpapers and another one for Facebook Covers. I noticed that even though I have different pages and sections for these – the prev/next go right from one category to another.

    Is it possible to only have the prev/next go to the same category of the portfolio item being displayed?

    Please let me know. Thanks so much!




    Open functions-enfold.php then find this code

    function avia_post_nav($same_category = false)

    Replace it with

    function avia_post_nav($same_category = true)

    Remove browser cache the reload the page.




    Hey there,

    I tried that and it simply took away the portfolio ‘prev/next’ navigation entirely.

    You can check it out here: “”

    I have two items in ‘Desktop Wallpapers’ and two items in “Facebook Covers’

    If you land on the page above.. I want to only be able to navigate to the other “Desktop Wallpapers” by using the Prev/Next. Same thing if you happen to be viewing a “Facebook Cover”. You should only be able to prev/next within the category you’re in.

    Here is the current code (for the line you specified):

    function avia_post_nav($same_category = true)


    No, unfortunately this is not possible due to a bug (or tbh it’s more a limitation) of the get_next_post()/get_previous_post() function – see: (Purchase code hidden if logged out) -two-completely-seperate-portfolios

    Probably the WP devs will fix this in WP3.6 or 3.7 and then you can also use these functions with custom post types and the portfolio.


    Ok, thanks for the response. Maybe on the next update! :)

Viewing 5 posts - 1 through 5 (of 5 total)

The topic ‘Can Prev/Next on Portfolio be category specific?’ is closed to new replies.