RubaXa jquery.fileapi setting preview el class -
RubaXa jquery.fileapi setting preview el class -
it possible set dynamically class of element contain preview of file based of file type? illustration image file have:
preview:{"width":100,"height":100,"el":".image-div-class"}...
and txt file have
preview:{"width":100,"height":100,"el":".text-div-class"}...
thank you
to append not image files type different div need use:
preview:{"width":100,"height":100,"el":".image-div-class""get": function ($el, file) { $el.appendto(".file-type-'+file.name.split('.').pop()+'").append("<p>"+file.name+"</p>");; }}
jquery fileapi
Comments
Post a Comment