Demonstration for validating image dimensions when you are uploading image files. This is applicable only for image files and if showPreview
is true
.
Not seeing the updated content on this page! Hard refresh your browser to clean cache for this page (e.g. SHIFT-F5 on Windows Chrome)
minImageWidth
and minImageHeight
. <!-- MINIMUM IMAGE DIMENSIONS --> <div class="file-loading"> <input id="input-dim-1" name="input-dim-1[]" multiple type="file" accept="image/*"> </div> <script> $("#input-dim-1").fileinput({ uploadUrl: "/file-upload-batch/2", allowedFileExtensions: ["jpg", "png", "gif"], minImageWidth: 50, minImageHeight: 50 }); </script>
maxImageWidth
and maxImageHeight
. <!-- MAXIMUM IMAGE DIMENSIONS --> <div class="file-loading"> <input id="input-dim-2" name="input-dim-2[]" multiple type="file" accept="image/*"> </div> <script> $("#input-dim-2").fileinput({ uploadUrl: "/file-upload-batch/2", allowedFileExtensions: ["jpg", "png", "gif"], maxImageWidth: 250, maxImageHeight: 250 }); </script>
Comments & Discussion
Note
You can now visit the Krajee Webtips Q & A forum for searching OR asking questions OR helping programmers with answers on these extensions and plugins. For asking a question click here. Select the appropriate question category (i.e. Krajee Plugins) and choose this current page plugin in the question related to field.
The comments and discussion section below are intended for generic discussions or feedback for this plugin. Developers may not be able to search or lookup here specific questions or tips on usage for this plugin.