How to display archive by selecting year and then selecting month

Unfortunately there is no way to nest wp_get_archives to achieve this, so you will have to build your own loop using get_month_link Like this (untested, regard this as a starting point): $year = 2009; while ($year =< get_the_time(‘Y’)) { echo ‘<ul>’ $month = 1; while ($month =< 12) { $link = get_month_link ($year, $month); if … Read more

Second page of archive is empty

How is the archive.php of your own theme looks like? Are you creating your theme based on underscore? You probably missing the get content part after the pagination. For example, here is part of the archive.php based on underscore theme: if ( have_posts() ) : ?> <header class=”page-header”> <?php the_archive_title( ‘<h1 class=”page-title”>’, ‘</h1>’ ); the_archive_description( … Read more

WordPress custom query by archive title

I have just made this on a rush but would you please try this : <?php if( is_tag() ){ $tag = single_tag_title(”, false); }else{ $tag=”; } if( is_category() ){ $cat = single_cat_title(”, false); }else{ $cat=””; } $args = array( ‘post_type’ => ‘post’, ‘post_status’ => ‘publish’, ‘tag’ => $tag, ‘posts_per_page’ => $ppp, ‘category_name’ => $cat, ‘offset’ … Read more

custom browse by

In your tag code you are missing a few quotes chars, the $tag var, and you cant endforeach like that i add braces for it: <div class=”tag-cloud” style=”margin: 20px 0;”> <?php echo ‘<select class=”tags”>’; // Add custom option as default echo ‘<option>’ . __(‘Select Tag’, ‘text-domain’) . ‘</option>’; // Get categories as array $tags = … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)