[wp-trac] [WordPress Trac] #24790: Attachment of posts not working
WordPress Trac
noreply at wordpress.org
Wed Jul 17 21:11:16 UTC 2013
#24790: Attachment of posts not working
-----------------------------+-----------------------------
Reporter: rajd9898 | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Post Thumbnails | Version: 3.5.2
Severity: critical | Keywords: needs-testing
-----------------------------+-----------------------------
{{{
$arrImages =&
get_children('post_type=attachment&post_mime_type=image&post_id=' .
$lnumber );
foreach ( $arrImages as $attachment_id => $attachment ) {
if ($counter <= $imgnum) {
$image_attributes =
wp_get_attachment_image_src( $attachment_id, 'medium' );
$output .= '<div class="gallwidg" >' .
wp_get_attachment_image( $attachment_id, 'medium' ) . '</div>';
$counter++;
}
}
}}}
this is a code to fetch images inserted in post. But some how this is not
working properly with 3.5.2 and 3.5.1 version of wordpress.
Attachment working fine with 3.5 version of wordpress
--
Ticket URL: <http://core.trac.wordpress.org/ticket/24790>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list