I’ve been searching high and low for an answer.
I simply want to remove the Alternate Text, Caption, Description and Link URL-fields from the uploader and gallery view.
I seem that every thing else than this Media-thingy can be removed.
Thanx for helping out:)
You can do this via a filter. Add the following to functions.php. You can also add your own fields this way…
The example above strips out more than you need to but if you do a
print_r()
on the$form_fields
variable you’ll see what’s available to add/remove.Unfortunately it looks like this changed quite a bit in WP3.5 when they upgraded the media library. That filter’s $form_fields parameter doesn’t contain the defaults any more. The only solution I’ve found so far is to forcibly remove the markup from the view using buffering:
This is extremely fragile – any change to the WordPress core might break this
Since WP 3.5, the simplest way is to just remove fields with CSS:
This is focused on images, but you can add anything to it…
I know it’s a really old question, but I was looking for a feature like this right now, and @Jake ‘s answer was the closest to the solution I got myself, which is adding to the style.css
this removed the whole meta fields part, leaving image details like file name, image size and upload date.
The sanchothefat’s Answer is correct, really Works like a charm.
Just for increase his answer, you can use
unset( $form_fields['image_alt'] );
to remove the Alternate Text.Thanks for Answering sanchothefat, it Helped me.