Skip to content

Commit

Permalink
Update to match changeset 21778 in WordPress, which allows for an 'id…
Browse files Browse the repository at this point in the history
…s' parameter to explicitly set the images and order the images are shown. http://core.trac.wordpress.org/changeset/21778
  • Loading branch information
Justin Tadlock committed Sep 11, 2012
1 parent b30a9a4 commit c645d7b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions extensions/cleaner-gallery.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ function cleaner_gallery( $output, $attr ) {
'captiontag' => 'dd',
'columns' => 3,
'size' => 'thumbnail',
'ids' => '',
'include' => '',
'exclude' => '',
'numberposts' => -1,
Expand All @@ -87,9 +88,9 @@ function cleaner_gallery( $output, $attr ) {
'post_type' => 'attachment',
'post_mime_type' => 'image',
'order' => $order,
'orderby' => $orderby,
'orderby' => !empty( $ids ) ? 'post__in' : $orderby,
'exclude' => $exclude,
'include' => $include,
'include' => !empty( $ids ) ? $ids : $include,
'numberposts' => $numberposts,
'offset' => $offset,
'suppress_filters' => true
Expand Down

0 comments on commit c645d7b

Please sign in to comment.