display post according to the term
Create template according Template Hierarchy. Place your design + posts loop inside. To list your custom taxonomy use wp_list_categories
Create template according Template Hierarchy. Place your design + posts loop inside. To list your custom taxonomy use wp_list_categories
Use a taxonomy.php template?! taxonomy.php <?php get_header(); ?> <?php $term = get_term_by( ‘slug’, get_query_var( ‘term’ ), get_query_var( ‘taxonomy’ ) ); ?> <h1><?php echo $term->name; ?></h1> <?php global $query_string; query_posts( $query_string . ‘&orderby=title&order=asc’ ); if (have_posts()) : ?> <?php while (have_posts()) : the_post(); ?> <h1><a href=”https://wordpress.stackexchange.com/questions/72934/<?php echo get_permalink(); ?>” title=”<?php the_title(); ?>” rel=”bookmark”><?php the_title(); ?></a></h1> <?php … Read more
You can build a list using two functions: get_terms() and get_term_link(): <?php function wpse73271_get_term_archive_link_list( $taxonomy ) { // First, get an array of term IDs $term_objects = get_terms( $taxonomy ); // Now, loop through $term_ids and get // an array of term archive permalinks foreach ( $term_objects as $term_object ) { $term_object->url = get_term_link( $term_object, … Read more
If I understood this correct, then you need a taxonomy.php file. LINK
No, it is not possible to order by taxonomy, because from a certain type of standpoint, that doesn’t actually make much sense. Taxonomies are ways to group things together. So the point of having a taxonomy on posts would really be to have terms in that taxonomy that are shared between posts. If a taxonomy … Read more
The bulk of your question seems to me to be about Cubepoint’s API, with is off topic here. The WordPress part would be this: I am not sure how your system works, or is supposed too work, but it sounds like you want to hook into save_post, but I am guessing about that part. Maybe … Read more
Looking at what you’ve tried (in your commented code), I think you’re close. I’m going to go out on a limb and guess that your event_date meta field is not stored as a numeric timestamp, which is what you were comparing against. Assuming it is stored as a text date like ‘2012-12-08’ (and if not, … Read more
This is not a taxonomy field you need, because as you described, the name of the field will stay constant for every category, but its value will change for every post. So the field should be attached to the post, not to the category. What you actually need to use is a post custom field, … Read more
Probably something like this: $records = new WP_Query( array( ‘post_type’ => array(‘record’), ‘post_per_page’ => -1, ) ); while ( $records->have_posts() ) : $records->the_post(); $terms = wp_get_post_terms( get_the_ID(), ‘planets’ ); if ( count( $terms ) === 0 ) { echo ‘Post ID: ‘ . get_the_ID() . ‘<br />’; } endwhile; wp_reset_postdata();
Thanks every one for help, I discovered that that the problem is from my theme admin that was limiting the posts to 5 and fixed now.