I am able to upload several files with drag and drop options.
I am facing the following issues.
- I successfully locate the drag in the drag zone and drag a different preview div (dz) to the dragenter . On leaving the drag, the default preview should be shown again. Without defining the draggle function, the drawer function is working fine.
- For drag rays, the plugin is not responding as desired. It appears that drag-left is a super-drawn dronder function.
This is my code
HTML
& lt; Div id = "preview" square = "drop zone" & gt; & Lt; Div class = "dz-drag" & gt; & Lt; H2 & gt; & Lt; I class = "glyphine glyphine-arrow-down" & gt; & Lt; / I & gt; & Lt; / H2 & gt; & Lt; P & gt; Drop files here & lt; / P & gt; & Lt; / Div & gt; & Lt; Div class = "dz-preview default" & gt; & Lt; I class = "glyphicon glyphicon-plus" & gt; & Lt; / I & gt; & Lt; / Div & gt; & Lt; / Div & gt;
JS
var myDropzone = new Dropzone (document.body, {// make the entire body a dropzone url: "insert-status.php" Set the // url method: 'POST', the nomenclature: 'image', parallel uploads: 1, addRemoveLinks: right, uploadMulti: false, thumbnailsNorth: 80, ThumbnailHight: 80, AutocuAU: incorrect, // Make sure the files' T queued until manually added guideline: "Sorry, something went wrong, please try again.", Preview: Container: "#preview", // Container Definition Show the clickable preview to display: ".file-click, #preview", // Define all clickable elements for this drop zone acceptable files: "Image / JPEG, Image / JPG, Image / GIF, Image / PNG, Image / BMP, Video / MP4, Video / AVI, Video / MVI, Video / 3GP ", Drentor: Function (file) {$ ('.dz-preview'). Wrap (); $ ( '.dz-drag'). Show (); $ ('preview-cont'). AddClass ('added'); // How the former Observation container}, drelev: function (file) {warning ('leave'); Hide $ ('drag dz.') () .; $ ('.dz-preview') show () .; Removeclass ('added') $ ('preview remaining part') // Preview preview container $ ('preview-cont'). RemoveClass ('Added'); // Hide Preview Container - Not working}, drop: function (file) {$ ('.dz-preview'). Show (); Hide $ ('drag dz.') () .; }
css
.preview-cont: not (.added) {display: none; } .dz-preview.default {width: 80px; Margin: 5px 3px; Limit: 0.17 mm dashed RGBA (0,0,0,0.15); -webkit-border-radius: 2px; -moz-border-radius: 2px; Border-radius: 2px; } .dz-preview.default .glyphicon {status: Completed; Margin top: 35%; Margin-left: 40%; Color: RGBA (0,0,0,0.15); Font-weight: 500; Font-size: 150%; } .dz-preview.default: hover {border color: RGBA (0,0,0,0.23); }. Dz-preview.default: hover & gt; .glyphicon {color: RGBA (0,0,0,0.23); }. Dz-drag {display: none; Width: 100%; Background: RGBA (255,255,255,0.7); Text-align: center; Limit: 2px dashed RGBA (0,0,0,0.2); -webkit-border-radius: 2px; -moz-border-radius: 2px; Border-radius: 2px; }
- Also, to know if a file that is already present in my drop zone, it should be added, garbled, uploaded Having or any other file status Is there a way by which I can detect the presence of the file, apart from being created in the GetFilesWithStatus function? My intention is to find out from a function call.
- I have handled the maximum filariasatch function by disabling / hiding the clickable link and button. Now, when the previous file is deleted, I want to re-enable all disabled links. I have not found any way for this operation.
-
Try the drawer and dragge
< / Li> -
View 1.
-
Not sure what "search file presence" means, but with the help of the drop event?
-
I used the deleted event event, and I only count how many preview templates are on the page if 0, the last file was removed.
No comments:
Post a Comment