WordPress.org

Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #21110


Ignore:
Timestamp:
06/29/12 07:25:58 (3 years ago)
Author:
ocean90
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #21110 – Description

    initial v1  
    11Using WP 3.3.2, the following statement worked perfectly: 
    22 
    3 <?php[[BR]] 
    4 $args = array( 'numberposts' => '3', 'post_status' => 'publish' );[[BR]] 
    5 $recent_posts = wp_get_recent_posts( $args );[[BR]] 
    6 foreach( $recent_posts as $recent ){[[BR]] 
    7 echo '<li id="date"><a href="' . get_permalink($recent["ID"]) . '" title="'.esc_attr($recent["post_title"]).'" >' .  get_the_date('M d') . '</a></li><li><a href="' . get_permalink($recent["ID"]) . '" title="'.esc_attr($recent["post_title"]).'" >' .   $recent["post_title"].'</a> - '.esc_attr($recent["post_excerpt"]).'</li><li id="breaker"></li>';[[BR]] 
    8 }[[BR]] 
     3 
     4{{{ 
     5<?php 
     6$args = array( 'numberposts' => '3', 'post_status' => 'publish' ); 
     7$recent_posts = wp_get_recent_posts( $args ); 
     8foreach( $recent_posts as $recent ){ 
     9echo '<li id="date"><a href="' . get_permalink($recent["ID"]) . '" title="'.esc_attr($recent["post_title"]).'" >' .  get_the_date('M d') . '</a></li><li><a href="' . get_permalink($recent["ID"]) . '" title="'.esc_attr($recent["post_title"]).'" >' .   $recent["post_title"].'</a> - '.esc_attr($recent["post_excerpt"]).'</li><li id="breaker"></li>'; 
     10} 
    911?> 
     12}}} 
     13 
    1014 
    1115However, since upgrading to 3.4 -- and subsequently to 3.4.1 -- the output contains the date on which the list appears vs. the individual post dates. For example,