Make WordPress Core


Ignore:
Timestamp:
12/05/2006 10:37:19 PM (19 years ago)
Author:
ryan
Message:

Attachment data abstraction from mdawaffe. fixes #3440

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/post-template.php

    r4603 r4612  
    354354    $mime = $post->post_mime_type;
    355355
    356     $imagedata = get_post_meta($post->ID, '_wp_attachment_metadata', true);
    357 
    358     $file = get_post_meta($post->ID, '_wp_attached_file', true);
     356    $imagedata = wp_get_attachment_metadata( $post->ID );
     357
     358    $file = get_attached_file( $post->ID );
    359359
    360360    $exts = array('jpg', 'gif', 'png');
    361 
    362361    if ( !$fullsize && !empty($imagedata['thumb'])
    363362            && ($thumbfile = str_replace(basename($file), $imagedata['thumb'], $file))
Note: See TracChangeset for help on using the changeset viewer.