Modifying the media-template.php file, the right way?

The shortcode accepts the columns=”0″ as an attribute so that it doesn’t insert any breaks in the HTML between gallery items, however this option is not available in Gallery Settings interface (“Add Media” pop-up when editing pages/posts). I’ve located the code in wp-includes\media-template.php line 396 to 406; <label class=”setting”> <span><?php _e(‘Columns’); ?></span> <select class=”columns” name=”columns” … Read more

Best approach when modifying the Media Manager

I am trying to edit the Media Manager to allow the selection of a new option in the “Link to” select field. This Backbone template is currently defined in media-template.php <label class=”setting”> <span><?php _e(‘Link To’); ?></span> <select class=”link-to” data-setting=”link” <# if ( data.userSettings ) { #> data-user-setting=”urlbutton” <# } #>> <option value=”post” <# if ( … Read more

Adding more options to the instance of an image. (Attachment Display Settings)

I’m trying to build a simple reusable plugin for image presentation in WordPress 3.9, and it seems I’ve hit a brick wall. I would like to be able to add a couple of options to the instance of the image. (The details under “Attachment Display Settings”). Like a checkbox that says “Responsive” that disables (grays … Read more

How to delete resized (cropped) image uploads and prevent future resizing?

I want to delete all the resized images while leaving the original image. I have more than 20 GB of unused data taking up room on the server. For example: first-image-name.jpg first-image-name-72×72.jpg first-image-name-150×150.jpg first-image-name-250×250.jpg first-image-name-300×300.jpg first-image-name-400×400.jpg first-image-name-1024×1024.jpg second-image-name.jpg second-image-name-72×72.jpg second-image-name-150×150.jpg second-image-name-250×250.jpg second-image-name-300×300.jpg second-image-name-400×400.jpg second-image-name-1024×1024.jpg Is there a way to delete all the resized images and … Read more