The tag has no wiki summary.

learn more… | top users | synonyms (1)

1
vote
3answers
455 views

get_terms orderby name as numbers

I have a custom taxonomy filled with terms such as 'volume 1', 'volume 2', 'issue 1', 'issue 2', 'issue 10' and get_terms orderby name returns list as: issue 1, issue 10, issue 2 though I need it to ...
0
votes
3answers
118 views

Order by a meta fiel in query loop

I would like to sort my article from a category by a number added in a meta field. Here is the first step, I get the articles to display on the page. <?php $cat = get_post_meta( get_the_ID(), ...
2
votes
2answers
2k views

Sort Posts by Multiple Meta Values

1) Custom Post Type named "Buying_Locations" 2) Each Post has three meta values of: State, City, Store Name QUESTION: How can you show a list of these posts sorted alphabetically by State, then ...
0
votes
2answers
388 views

Make custom post type column sortable

My site has two custom types: Auction and Lot. Lots are connected to an Auction via the post_parent field. I added an Auction column to the Lots list in the admin area. function ...
0
votes
2answers
86 views

Filter and Search

I am working on my site which is a WordPress based site. It is a sweepstakes site well winprizesonline.com is the site which inspired me most. Now I want a dynamic search like that site on my site but ...
0
votes
1answer
20 views

Posts with no meta field do not appear when sorting by meta field

I want to order my posts by a custom meta field "fieldA". I am using the following code: $query->set( 'meta_key', 'fieldA); $query->set( 'orderby', 'meta_value_num' ); $query->set( 'order', ...
0
votes
1answer
34 views

Sorting get_post_ancestors array

I have written this code for my breadcrumbs (i'll give only the part that I have problem with): } elseif (is_page()) { if($post->post_parent){ $anc = get_post_ancestors( $post->ID ...
0
votes
1answer
45 views

Sort loop with query in the link

I want to add some buttons that will sort the post by name asc/desc etc. I want to use query in the link like this http://domain.tld/?orderby=name&order=asc Is this safe to use? Are there ...
0
votes
1answer
266 views

Sort All Posts by Category Name in the Admin Panel?

I'm working on a pretty complicated site where everything is managed by category type including automatic spinner image submission, etc.. Unfortunately, its doggone difficult to manage things when the ...
0
votes
1answer
45 views

How do I sort post listing by child post count?

I have two custom post types called questions and answers. The questions list includes a custom column which displays a count of the answers for each question. I need to be able to sort the listing ...
0
votes
1answer
103 views

wp_query by last month + sort posts

I'm using the WordPress plugin 'I recommend this', it allows people to 'like' posts. The value is stored as a meta key, which we can query to generate a 'most recommended' page. Plugin -> ...
0
votes
1answer
17 views

Wordpress - show all posts + ones with specific tag

I have 3 types of posts as below Normal posts without any tag With "featured" tag With "sold" tag On a page, I just want to show normal posts + ones with featured tag and don't want to show posts ...
0
votes
1answer
75 views

Add Sort Link in Custom Post Type List

I need to add a link here, beside the Published link: How can I do it? I'm trying to filter my custom post type by meta values and need a link to do it. Thanks.
0
votes
1answer
187 views

How to get alphabetic listing x other posts, based on first letter post?

Let's say I have a post called "Hello World" and I am on that page... Let's say I have different posts like "Haaaa" and "Hoooo".... What I want to do is showing Haaa and Hooo in a different place (let ...
0
votes
1answer
45 views

List CPT by menu_order with children right after parent

I registered a custom post type drawer where my posts are ordered using menu_order. Each drawer could be a child of another drawer, on a multiple depth (parent > child > child of child > child of ...
0
votes
1answer
54 views

sort custom post type by display name

I am trying to sort my custom post type in a few different ways using a dropdown. When I try to sort it as the display_name it doesn't work. $wp_query = new WP_Query(array('orderby' => ...
0
votes
1answer
171 views

Sort categories by meta value

How can I make a list of categories with 4 last posts in each where every category is sorted by meta_value. For example, template without sorting by meta_value is http://pastebin.com/AeH6vx9b It ...
0
votes
1answer
70 views

How can users sort multiple pages?

I'm using the following code to display a list of properties on multiple pages. I would like to give users the option of sorting the results by custom fields (perhaps city, or property name, or ...
0
votes
1answer
409 views

WP_Query -> sort results by relevance (= most tags / taxonomy terms in common)

I'm trying to write a new "related posts" widget (for the single post view) for my custom post type, filtering by custom taxonomy terms that the related posts should have in common with the current ...
0
votes
1answer
50 views

Link to most recently created category of custom taxonomy in primary navigation menu

I have a custom taxonomy called Issues (like magazine issues) with categories named after the title of each issue. I created a page called "Current Issue" and added a link to it in the main ...
0
votes
1answer
35 views

list pages by custom_field?

Is there a way for me to sort these posts alphabetically according to the custom field I have defined (last_name)? <?php $page_id = get_the_ID(); $args = array('sort_order'=>'DESC', ...
0
votes
1answer
152 views

Sort by category and then date?

I'll try to be as clear as possible. My Wordpress site has multiple custom categories and posts types all which need to be displayed on the home page blogroll. But I need the first post on the ...
-1
votes
1answer
87 views

How do i Sort my Posts

I search for a solution how i can sort the article in my page. I searched for hours in google and try severla things but nothing works :( . Anyway, maybe anybody has a good tip for me. I want a ...
-1
votes
1answer
304 views

Sort author list alphabetically

I have narrowed the code down to this: <?php $authors = $wpdb->get_results('SELECT DISTINCT post_author FROM '.$wpdb->posts); if($authors): foreach($authors as $author): ...