Closed goldenapples closed 7 years ago
I think unless we could hook into the insertion to place a shortcode instead of PDF link, maybe we should consider leaving the filter out at this point.
Well, the filter on post_mime_types
was only there so that I could have our attachment picker in the shortcode UI pull up a view with only PDFs - since I couldn't figure out a way to add a mime type filter for the media frame in Shortcake without adding it globally.
But you bring up a good point. I added a filter on media_send_to_editor
, so that any PDFs added through this method get inserted as the [pdf]
shortcode, rather than the link which WP sends by default.
Sweet! This is a nice addition.
Adds an attachment field to the PDF shortcode UI, which allows uploading a local attachment or selecting from already uploaded PDF attachments.
Adds a new option to the "type" dropdown in the media library for "application/pdf" documents.
See #192