WordPress.org

Make WordPress Core

Changeset 7749


Ignore:
Timestamp:
04/20/08 06:45:13 (7 years ago)
Author:
ryan
Message:

Fix pass by ref error. Props DD32. fixes #6776 for trunk

File:
1 edited

Legend:

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

    r7747 r7749  
    374374// get an attachment page link using an image or icon if possible 
    375375function wp_get_attachment_link($id = 0, $size = 'thumbnail', $permalink = false, $icon = false) { 
    376     $_post = & get_post( intval($id) ); 
     376    $id = intval($id); 
     377    $_post = & get_post( $id ); 
    377378 
    378379    if ( ('attachment' != $_post->post_type) || !$url = wp_get_attachment_url($_post->ID) ) 
Note: See TracChangeset for help on using the changeset viewer.