Exclude Post ID from Array Specified in Custom Field

Your question is pretty vague and you haven’t given any example code, but the following may work for you: <?php global $post; // Arguments $args = array(‘ /* Enter your arguments in here… */ ‘); // The query $the_query = new WP_Query( $args ); // The loop if ( $the_query->have_posts() ) { // Exclude ID … Read more

Problem displaying replies as part of author’s latest comments on author page

My bad. Should have added a foreach for the replies as well. <?php $args = array( ‘user_id’ => $curauth->ID, ‘number’ => 5, ‘status’ => ‘approve’, ‘parent’ => 0 ); $comments = get_comments($args); if ( $comments ) { foreach($comments as $c){ echo ‘<ul id=”authorcomments”>’; echo ‘<li>’; echo ‘<a id=”authorcommentlink” href=”‘.get_comment_link( $c->comment_ID ).'”> ‘; echo get_the_title($c->comment_post_ID); echo … Read more

Create dropdown menu of all tags used in category

Try building a master $posttags array like so: <?php $post_tags = array(); $the_query = new WP_Query( ‘posts_per_page=50&cat=89’ ); if ( $the_query->have_posts() ) : while ( $the_query->have_posts() ) : $the_query->the_post(); $posttags = get_the_tags(); foreach( $posttags as $posttag ) { $post_tags[$posttag->slug] = $posttag->name; } endwhile; endif; ?> <ul class=”dropdown filter option-set clearfix” data-filter-group=”tags”> <li><a href=”#filter-tags-all” data-filter-value=”.item” class=”selected”>All … Read more

Exclude Tags by Array

You could achieve this with get_terms() and ‘name__like’ => ‘Author:’ argument. See linked documentation. From architecture perspective, however, you probably shouldn’t be (ab)using tags for this. It would make sense to split your authors into custom taxonomy. It would be more clear semantically, as well as easier to deal with in interface and code.