One of my favorite things about the WordPress API is the ability to store custom meta data with objects such as pages and users. I’ve been working on an application where this scenario has presented itself: The end user is able to create a company Each company can have an administrator based on users in […]
Search: “wp_query” (Page 7 of 29)
We found 145 results for your search.
[…] with anything that’s related to programming, there are a number of ways to do this, but if you’re working with WordPress then you’re best bet is to use WP_Query. If you’re working with the standard post types (like, you know, all published posts), then you won’t need to be as explicit in your code as […]
[…] their Sticky Posts, then I’ll introduce a feature that makes this easier. A Word on Query Optimization When working on these plugins, I was attempting to use WP_Query (which I’ve used in a variety of other projects) to identify the posts that I had marked as sticky for a given category or tag as […]
[…] queries run on any given page along with their order and the amount of time it took to run each one of them, any information about the WP_Query object that is relevant (some pages don’t have anything, some will) Furthermore, we gain insight into: hooks, theme information, PHP errors, request information, JavaScript, CSS, language […]
[…] may have a bit more work per function than usual. Querying For Posts First, we need to query for posts. To do this, we’ll take advantage of WP_Query. View the code on Gist. Notice that we return the instance of the query object. We’ll do more with this momentarily. Displaying a Result If there […]
