-4
votes
2answers
984 views

How can I display sticky posts at first in wp_query?

I'm looking for a long time, but I could not find a solution. I'm not a coder. Please help me. Here is my wp_query code; $my_query = new WP_Query('category_name=animals&showposts=10'); while ...
1
vote
1answer
79 views

Keep sticky posts out of query unless they have featured image

I have a query running which prevents posts without various criteria from appearing, one of these is the necessity to have a featured image. Sticky posts however seem to end up in the query ...
0
votes
1answer
511 views

wp_query should show stickies first

I have the problem that my theme is for some reason always showing the latest posts at first. I would however like it to show all stickies at first and then show the regular ones. Here is the code: ...
1
vote
3answers
1k views

wp_query for the first sticky, then display the rest of the posts excluding the first sticky

I've been reading this by @nacin and getting to grips with wp_query over query_posts that I used to use. What I want is: to put this in a template file to query all posts of this category, in this ...
-1
votes
2answers
327 views

First post outside of loop, homepage only?

Because of the way my templates are structured, I need to pull the first/sticky post from the site outside of the standard loop, just on the homepage. I'm using _s (underscores.me) as a base, so the ...
0
votes
1answer
891 views

Multiple loops on index page with sticky post and pagination

First post on this site. Hope to get some help from you guys. Probably a simple answer for you experts. I have two category's (news & work). I want to show on my index page (wordpress ...
1
vote
2answers
3k views

Custom loops, sticky posts, and pagination nightmare

I've tried everything. I've looked at every. single. question. here, on StackOverflow, the WP help forum, googled 10 pages deep and literally tried EVERY combination of code I could find, for the ...
4
votes
0answers
499 views

Sticky Posts & Posts Per Page [closed]

I notice that sticky posts will disregard the posts_per_page param? Like I have a query like $q = new WP_Query(array( 'posts_per_page' => 4, ... )); If there are 3 sticky posts, I will get 6 ...
1
vote
2answers
2k views

Excluding Sticky Posts from The Loop and from WP_Query() in WordPress?

The following snippet is from a sidebar widget that lists "recent posts". Since its on the home page and I feature my lastest sticky post prominently on that page, I want to skip over the sticky in ...