Formatting, adding/updating links

This commit is contained in:
Ben Word
2013-11-07 21:28:52 -06:00
parent e362daecf2
commit 840ee637bf
14 changed files with 23 additions and 21 deletions

View File

@@ -5,7 +5,7 @@
* Re-create the [gallery] shortcode and use thumbnails styling from Bootstrap
* The number of columns must be a factor of 12.
*
* @link http://twbs.github.io/bootstrap/components/#thumbnails
* @link http://getbootstrap.com/components/#thumbnails
*/
function roots_gallery($attr) {
$post = get_post();
@@ -88,16 +88,16 @@ function roots_gallery($attr) {
$image = ('file' == $link) ? wp_get_attachment_link($id, $size, false, false) : wp_get_attachment_link($id, $size, true, false);
$output .= ($i % $columns == 0) ? '<div class="row gallery-row">': '';
$output .= '<div class="' . $grid .'">' . $image;
if (trim($attachment->post_excerpt)) {
$output .= '<div class="caption hidden">' . wptexturize($attachment->post_excerpt) . '</div>';
}
$output .= '</div>';
$i++;
$output .= ($i % $columns == 0) ? '</div>' : '';
}
$output .= ($i % $columns != 0 ) ? '</div>' : '';
$output .= '</div>';