456 posts
  • 6 Years of Membership
  • Affiliate Level 1
  • Author Level 2
  • Collector Level 2
+2 more
godonholiday
says

Is it possible to set a post as a sticky item for a category in WP. I want to be able to click on the category link and then when I am taken to the category page (Where all the post are shown) Have one that stays on the top of the stack.

I want these for all of my categories? Is that possible?

Thanks,

Gavin

456 posts
  • 6 Years of Membership
  • Affiliate Level 1
  • Author Level 2
  • Collector Level 2
+2 more
godonholiday
says

Is this not possible? I cant seem to find any information about it.

1680 posts Chris Robinson
  • Elite Author
  • Author Level 10
  • 7 Years of Membership
  • United States
+13 more
contempoinc
says

Take a look at this

456 posts
  • 6 Years of Membership
  • Affiliate Level 1
  • Author Level 2
  • Collector Level 2
+2 more
godonholiday
says

Thanks, I have read that, and have struggled to implement it.

On the page that displays all the posts for a category I want a sticky post at that top (To kind of introduce the category).

If I just make that post a sticky, then it will stick to the top on my home page.

I am trying to change/play with the code in the codex to exclude all the other categories.

Then go through and do the same for each category.

Is this how you would go about this? or is my method wrong?

Thanks for the link.

743 posts
  • Elite Author
  • Weekly Top Seller
  • Featured Item
  • Most Wanted Winner
+5 more
Orbital_Themes
says

If you are not planning to use tags anywhere else you could make use of Wordpress tagging system. Tag a post as sticky, than loop through the same query two times. For the first time use conditional statement to detect if post has tag “sticky”, if not than continue (ommit the post). Than re-loop, but this time ommit “sticky” posts and display only posts without “sticky” tag.

It’s just an idea, you know, try playing around with it :)

204 posts Bold WordPress Theme Development
  • 6 Years of Membership
  • Affiliate Level 5
  • Author Level 9
  • Blog Interview
+7 more
srhnbr
says

If this is to “To kind of introduce the category” then depending on the type of information you need to display you can easily use a category specific image and the category’s name and description as text.

Let me know if you need some example code

by
by
by
by
by
by