Create an archive listing based on meta array

Have you looked at PHP’s date function? A quick example : $dates = $wpdb->get_col( /*your sql*/ ); if( $dates ) { $archive_year = “”; foreach( $dates as $date ) { $the_date = strtotime( $date ); $year = date( ‘Y’, $the_date ); //4 digit year, ex 1999 $month = date( ‘F’, $the_date ); //Full textual month, … Read more

Different layout on second page

To load override WordPress’ choice of template you can use template_include filter and then use the locate_template to return the the template file path (if it finds it). The file-name passed to locate_template must be the name of the template file name (which should be in you theme/child-theme directory). //Loads template customtemplate.php from your theme … Read more

next_posts_link and previous_posts_link problem

When using custom post types I got around this problem by using the following code. Of course you will need to put in the HTML for how you want it to display on your site. <?php $temp = $wp_query; $wp_query= null; $wp_query = new WP_Query(); $wp_query->query(”); // Enter you query here ?> <?php while ($wp_query->have_posts()) … Read more

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