Install
This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.
Install straight from GitHub with WP-CLI:
wp plugin install https://github.com/sectsect/cfs-validate-image/archive/refs/heads/master.zipNo built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.
CFS Validate Image Add-on
Add Validate Image dimension and mime-type field type to Custom Field Suite.
Displays an alert and reject insertion to the image that does not meeting dimention requirements.:no_entry_sign: (Using sweetalert.js)
Requirements
- Activation Custom Field Suite Plugin.
Installation
cd /path-to-your/wp-content/plugins/git clone git@github.com:sectsect/cfs-validate-image.git
That's it:ok_hand:
Setting items
- min width
- min height
- max width
- max height
- Alert Message (
Image Dimention < Min Dimention) - Alert Message (
Image Dimention > Max Dimention) - Setting for rejecting a specific image mime-type
Change log
- 1.1.0 - Add image mime type validation
- 1.0.0 - Initial Release
Based on the CFS Google Maps Add-on by Matt Gibbs