One of the better approaches is to unregister WP’s default gallery shortcode function, and add your own customized replacement. WP engineer has a great post about it here. This also will let you fix that funky inline CSS that the default gallery adds to the page.
Related Posts:
- Detect if is image unattached
- Retrieving a custom link on an attachment
- how to test for attached image
- Gel all image from certain post type
- ID of images from gallery
- Hide “Gallery Settings” and “Insert into Post” button from Attachment window
- Getting attachment images is cloning some of them
- How to make a customized “Create Gallery” tab in the ‘Add Media’ window?
- Reorder “menu order” of attachments to another predefined order
- Add image attachment to post via coding?
- Ordering of gallery images without using shortcode in theme
- Custom Gallery HTML only working when images are attached to post/page
- Display random gallery images and its parent post title leading to parent post permalink
- Where does the gallery shortcode gets its attachments from?
- hide attached images of a post
- WordPress Gallery Permalink Structure Displaying Incorrectly
- How do I get just the title from wp_get_attachment_image
- changing the default picture size link url
- Programmatically Altering Gallery Link and image size?
- How is it possible that a gallery doesn’t have attachment ids?
- ID of images from gallery
- How to save media-form on custom tab
- Programmatically adding images to the media library with wp_generate_attachment_metadata randomly fails
- Trying to hide buttons from Attachment window
- Uploading Multiple Attachments From Front-End With A Description
- Validate alt text for attachments?
- complex restriction of items in media library
- Edit image / Delete image link
- How could I add button next to “edit image” button in “Attachment Details”
- Give attachments an archive page
- Insert Media – Attachment – Link to : Remove the “attachment page” option
- Can I attach a document (eg: PDF) but have a JPEG as a thumbnail?
- Delete attachments from Front end
- get post attachments of a particular size
- How to upload image from front end and save in media library?
- attachment url rewrite
- How to create a CSV on the fly and send as an attachment using wp_mail?
- Get the title and URL of the attachment parent post
- Confused with attachment mimetype order
- query attachment images … if no attachments -> get attachments of parent page?
- Replacing with(out) regex link to attachment by links to files
- rename attachments based on parent-post-title on upload
- Rename attachments during upload no matter what filetype
- Link all WordPress images size
- Contact Form 7 Data As Attachment [closed]
- Post Via Email – How to send Attachments with it (e.g. PDF File or JPEG Image)?
- Displaying Post Attachment(s) at Top of single.php
- Detach an image from a page using php
- Get the path of the first attached media (single.php)
- custom admin thumbnail for videos, not getting post’s id?
- Image Gallery Numbers for 3.5
- How do I link an image to the post it is attached to?
- How to delete a custom file from upload directory when deleting its post
- Open the Attachment Details popup
- How to compress image before inserting to wordpress using wp_insert_attachment function?
- Query to only return the 2 newest post attachments (images)?
- Getting “too many redirects” when using wp_redirect for attachment page
- Clean up images, delete unused image sizes attached to a post type
- What is the best way to store thumbnails for a non-image attachment?
- Change default selection for “Embed or Link”?
- What will happen if I delete all my attachment type posts from database?
- filter get_children to return all mime types EXCEPT ‘x’
- Weird string offset errors when displaying post attachments
- the_time() returning wrong date/time (way in the future)
- Add audio attachment link to RSS
- How to: Retrieve an attachment image from post and output it
- Links to my uploads went crazy
- How to add a caption to an image attachment in a file list?
- Echo list attachment size in post
- Undoing define( ‘UPLOADS’, ”.’files’ ); to repoint to “wp-content/uploads” folder
- Upload image and assign it’s id to post
- Possible to add “Even/Odd Classes” to image attachments via wp_get_attachment_image?
- Can’t sort get_posts by post_mime_type
- How to get thumbnail from post attachment in this loop
- How can I rewrite old attachment URLs?
- How to list “invisible” Auto Drafts?
- How to add media from front-end to an existing post and edit file title
- How can I customize the link when an attached image is clicked?
- Media item permalink goes to source file instead of attachment.php
- Display audio file in audio.php
- how to add data in my custom theme from WP-Admin Panel
- Display setting ‘size’ not available in image settings modal
- Attachment Metadata inside of Loop
- Attachment file display link text
- Retrieve ONLY mp3s and set a variable for use in a playlist called by single.php template?
- Get video attachment ID and display length
- missing attachment are showing as 404
- Insert attachments from front end form
- How do I add Facebook OpenGraph meta tags for attachments in the header for a custom theme?
- Add link to attachment for old posts
- Drupal 6 to WordPress migration – media attachments
- Retreive tags from attached post for media on page
- Move caption in on attachment page
- WordPress gallery image link gives 404 when not logged in
- Change attachment inside the_content using filters
- I want to edit documents on my blog without the need to download and upload files again [closed]
- Bulk delete media by year
- Count images in post then add class if just one
- One audio attachment, with two possible interchangeable extensions
- Image Attachments Query Not Working If Post Is Loaded Via Ajax