Make WordPress Core


Ignore:
Timestamp:
04/04/2013 08:09:02 AM (12 years ago)
Author:
markjaquith
Message:

Standardize the post format theme API functions with the_post_format_THING() and get_the_post_format_THING().

fixes #23927

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/media.php

    r23873 r23899  
    20322032 * @return string
    20332033 */
    2034 function get_the_media( $type, &$post = null ) {
     2034function get_the_post_format_media( $type, &$post = null ) {
    20352035    global $wp_embed;
    20362036
     
    21192119 *
    21202120 */
    2121 function the_video() {
    2122     echo get_the_media( 'video' );
     2121function the_post_format_video() {
     2122    echo get_the_post_format_media( 'video' );
    21232123}
    21242124/**
     
    21282128 *
    21292129 */
    2130 function the_audio() {
    2131     echo get_the_media( 'audio' );
     2130function the_post_format_audio() {
     2131    echo get_the_post_format_media( 'audio' );
    21322132}
    21332133
     
    23612361 * @param WP_Post $post Optional. Used instead of global $post when passed.
    23622362 */
    2363 function get_the_image( $attached_size = 'full', &$post = null ) {
     2363function get_the_post_format_image( $attached_size = 'full', &$post = null ) {
    23642364    if ( empty( $post ) )
    23652365        $post = get_post();
     
    24362436 * @param string $attached_size If an attached image is found, the size to display it.
    24372437 */
    2438 function the_image( $attached_size = 'full' ) {
    2439     echo get_the_image( $attached_size );
    2440 }
     2438function the_post_format_image( $attached_size = 'full' ) {
     2439    echo get_the_post_format_image( $attached_size );
     2440}
Note: See TracChangeset for help on using the changeset viewer.