Linked Questions

0
votes
3answers
165 views

Order by title without taking into account 'the'

I currently have episodes from a TV Show that feature bands playing, so for example I have: Moby The Dandy Warhols The Kooks My wp_query looks like this: $loop = new WP_Query(array('post_type' ...
0
votes
3answers
338 views

How can I show posts for a single category?

Is it possible to show posts for a single category? I tried browsing to the URL http://mysite.com/category/foo which does show all of the posts with category foo, but the posts lose their formatting ...
0
votes
3answers
4k views

Problems excluding a custom post-type from the loop

Morning all, I'm having some issues with excluding my custom post-type 'events' from my index.php loop for my Blog page. I simply want to display the posts from my actual Blog, which I assume come ...
7
votes
2answers
2k views

Looking for WordPress System Diagrams

I am looking for WordPress chart/diagram system design. I found only the template hierarchy diagram, but it's only part of the system. source: ...
5
votes
2answers
941 views

Differences Between WP_Query() and get_posts() for Querying Posts?

What are the differences between using WP_Query() and get_posts()? Which is better to use in what case and why?
4
votes
2answers
465 views

Wordpress the_content() return only one image from a specific category

I am working on a Wordpress website and I am using a loop to get all the posts that have title and body contain an image. But the problem is that it returns me all the titles but not all the images. ...
4
votes
2answers
4k views

query_posts() in function makes global $wp_query out of sync?

This has me stumped for a while already. Either I am missing something very obvious or something very not obvious. I am also not entirely sure if this has something to do with WP or purely PHP ...
4
votes
2answers
240 views

Show the First Post from Each of 3 Different Post Types on a Web Page?

I have 3 different custom post types: 1.) "events", 2.) "winners" and 3.) "offers". How would I go about retrieving the first (latest) post in each of these post types on a single web page (i.e a home ...
3
votes
2answers
2k views

Archive by Year

After some searching I haven't been able to find a answer to what I'm trying to archive. I'm trying to set up an archive page with accordion panels that hide/show posts from a given year with links. ...
2
votes
2answers
3k views

List posts by category exclude current post

I'm trying to get a list of posts from one category, echo the title and the permalink of all posts on that category but exclude the permalink and the post name IF the current post is on that list. It ...
2
votes
2answers
1k views

“pre_get_posts” firing on every query

How can I change arguments for the main query only, and not affect other queries? add_filter('pre_get_posts', 'custom_post_count'); function custom_post_count($query){ ...
2
votes
2answers
527 views

How to generate a list of posts published on current day?

I want to create a page labeled "Today's News" which displays a simple bulleted list of all posts published on the current day and grab the current date based on the server's date/time. Is this ...
2
votes
2answers
2k views

How to make multicheck for post/page meta box

Please help me understand how to make Multicheck type for metabox. Search for all internet and nothing. Thanks. UPDATE @Jan I have a headache from this function. I dont know whats wrong.I'm ...
1
vote
2answers
34 views

All posts are still shown when adding category argument to query

I've got the following code in my team-type.php file which I'm using to create a custom taxonomy for a member information: function create_team_taxonomies() { $labels = array( 'name' ...
1
vote
2answers
53 views

Different Ways to Query Custom Post Types?

I'm using this code to use custom post types like regular post: add_action( 'pre_get_posts', 'add_my_post_types_to_query' ); function add_my_post_types_to_query( $query ) { if ( is_home() && ...

15 30 50 per page