Howdy! Many people know me simply as DrewAPicture but my real name is Drew Jaynes. If you need to get in touch, you can email me at drew [at] drewapicture.com or send me a tweet at @DrewAPicture.
I've been working in and developing with WordPress since 2009. I do freelance WordPress design and development in Denver, Colorado. I also Co-Organize the Denver WordPress Meetup, contribute to core, and volunteer on the support and docs teams.
Since I'm in the Codex usually several times I day, most of my changes have been tweaks to example functions, clarifying and general copy editing as well as coding standards changes in articles throughout the Codex.
I'm interested in branching out into creating entirely new articles and assisting with general Codex cleanup efforts.
Please see my WordPress profile.
In WordPress, the Gallery feature allows you to one or more image galleries to your posts and pages.
Up until WordPress 3.5, the gallery shortcode was most often used in this form:
Following 3.5, you can still use parameters like before -- you can still use [gallery] just like before -- but it's more likely you'll see gallery shortcodes similar to this format:
This new-ish format (which was previously possible), allows you to include images in your gallery that aren't necessarily "attached" to your post -- that is to say, not uploaded from within your post or page. This flexibility allows you to create and embed any number of galleries containing any number of images!
Note: If you choose to just use the [gallery] shortcode in your post or page, the shortcode will only include images that are "attached" to that post or page. This is not new behavior to 3.5.
There are several options that may be specified using this syntax:
[gallery option1="value1" option2="value2"]
You can also print a gallery directly in a template like so:
<?php echo do_shortcode('[gallery option1="value1"]'); ?>
This works too:
<?php $gallery_shortcode = '[gallery id="' . intval( $post->post_parent ) . '"]'; print apply_filters( 'the_content', $gallery_shortcode ); ?>
The following basic options are supported:
[gallery order="DESC" orderby="ID"]
Some advanced options are available:
[gallery itemtag="div" icontag="span" captiontag="p"]