Tagged Questions
0
votes
1answer
106 views
Query Multiple Custom Post Types & Exclude a Taxonomy Term
I'm querying multiple custom posts types and I'd like to filter certain posts that are tagged with a specific taxonomy term.
The taxonomy is "content" and the term is "indy"
I'm using the the code ...
0
votes
1answer
47 views
What's the best way to show custom post types? With page template it's not perfect!
I created a custom post type with name career. I would like to know what's the best way to list the posts. I created a page template with a query inside, but the pager is invisible. I don't know ...
0
votes
1answer
110 views
pagination does not work with query_posts. Help! [duplicate]
I made a separate page template (added sidebar), this page contains all the posts. Pagination works!
But, if this page set as the home page, pagination is not working!
Please help find solutions ...
0
votes
1answer
32 views
How to apply order on custom taxonomy and custom meta key on custom post type
Here is the code in am using
$arg= array(
'post_type' => 'vr_listing',
'tax_query' => array(
array(
'taxonomy' => 'vr_listing_status',
'field' => ...
0
votes
2answers
71 views
Custom MySQL query to list post
I have the following query:
SELECT
p.*
FROM
orders_items oi
INNER JOIN products pr
ON pr.`post_id` = oi.`product_id`
INNER JOIN posts p
ON p.`ID` = pr.`post_id`
AND p.`post_type` ...
2
votes
1answer
367 views
Nested meta_query with multiple relation keys
I am curious whether Wordpress is able to run nested meta_query, with each having different relation keys? As of Wordpress 3.0, tax_query is able to perform this function; I'm wondering whether this ...
0
votes
1answer
159 views
Custom Queries - Child Categories not showing up
What I'm Doing
I have a cities category and normal categories. Right now I have them filtering by category, then when the user clicks a city it will filter by category AND city
query_posts(array( ...
0
votes
1answer
1k views
Filter Posts By Tag
I'm trying to filter my posts by category, then further by city. The only way I can think of filter by city is if the admin adds the city to the listed tags and then filtering from there via switch ...
2
votes
1answer
301 views
query_posts sort in multiple directions
I'm trying to improve my post sorting by using multiple criteria, but I want specific orders for different values. For example, I have a meta_key called 'featured' that I want to move any post up to ...
0
votes
1answer
466 views
Magazine style frontpage with multiple categories/loops and no duplicate posts
I am migrating a static magazine site to wordpress. I would like to have a frontpage displaying multiple categories with a few posts in each, e.g "politics", "environment", "health" and "technology". ...
0
votes
1answer
162 views
Query post types with multiple keys
I'm looking for a way to only show posts results that contain all of the custom fields requested. Not one or the other. I was only able to get results with one array at a time. Any help would be ...
0
votes
1answer
110 views
attach CPT data to a taxonomy
I'm trying to create a site where a 'Game' has a set of information (im thinking it will be a custom post type, with a 'link' field, 'developer' as a taxonomy, 'price', 'release date' and some other ...
1
vote
2answers
896 views
Conditional Query of Custom Post Type and custom taxonomy
I am working on a project that has
a custom post type called 'Experience Statement'
Custom Taxonomy attached to that post type called 'Expertise'
6 different terms for the custom taxonomy: Coastal, ...
0
votes
2answers
219 views
Query add html after set amount of posts?
Is it possible to add some html after a set amount of posts?
For the purposes of a slider after 6 posts i need it to enclose in a div/li or whatever then start a new div/li for the next 6 and so on.
...
0
votes
1answer
628 views
Filter my home page posts by category or by tag
Would like to filter my home page posts by category OR by tag.
i.e. only posts that are in category "X" or have tag "B" appear on the home page.
Have used code below successfully to filter ...
2
votes
1answer
292 views
Get all posts WHERE custom_field is LIKE value
I'm trying to do a MySQL-style search with Wordpress' built-in functions for fetching posts. There's likely a simple way to do this and I'm probably just a little bit off from the solution.
We have ...
0
votes
1answer
796 views
Wordpress loop problem: Multiple loops, index.php and is_paged causing duplicate posts on next page
Hey everyone. I'm not sure if what I'm experiencing is a result of a bug (due to the recent upgrade to 3.1.2) or poor coding. Ever since i upgraded to version 3.1.2 ive been experiencing a problem ...
1
vote
1answer
1k views
How to select posts from multiple categories and metavalues?
I need to select posts who are in multiple categories and have certain post metavalue. I can select multiple categories with
query_posts( array( 'category__and' => array(1,2,3) ) );
But also I ...
1
vote
2answers
1k views
Adding Variables to post query
How do I add custom variables to the wordpress query without having to hit the database twice. In the example below I want to add some meta filters. All this code works fine but I have been running ...
0
votes
1answer
515 views
Custom Post Type Query for Sidebar Doesn't Work on Front Page
Interesting issue here.
I have this:
$args=array(
'meta_key'=>'_simple_fields_fieldGroupID_1_fieldID_8_numInSet_0',
'post_type' => 'stores',
'post_status' => 'publish',
...
1
vote
2answers
2k views
Select category in custom query
I'm sure this question is asked alot, but I cannot figure it out, since all the different ways to query posts are confusing me..
Here is my current code.
How can I tell the code to only get posts ...