jquery.file.upload plugin wrapped as an angular directive

1,774 views
Skip to first unread message

pyrrhus...@gmail.com

unread,
Oct 12, 2012, 7:45:27 AM10/12/12
to ang...@googlegroups.com
hi,

This is my first venture into angular, but one of the things I really needed was a working file-upload for angular. So I built this based on the examples I found, and thought I'd share the result, some may find it useful.

http://jsfiddle.net/tech_no_logical/XG5We/

It is based on https://github.com/blueimp/jQuery-File-Upload/. The fiddle doesn't work because I can't upload files to jsfiddle (can I ?), but it should be pretty straightforward to get it running on your own server. Just update the action in the form to point to your server-side install of the jquery.file.upload plugin.

The progress-bar doesn't really work in internet explorer : it simply goes from nothing to 100% when the upload completes, but the behaviour is otherwise correct. Tested in firefox, chrome, IE8/9 and opera.

Additions, tips and other remarks welcome :)

--
CUL8R, Peter.

Lee Nathan

unread,
Jun 12, 2013, 6:20:08 PM6/12/13
to ang...@googlegroups.com
Nice work.
Just the starting point I was looking for.
Thanks for sharing.

Angel Estrada

unread,
Jun 13, 2013, 3:28:25 PM6/13/13
to ang...@googlegroups.com
Hi there, 

i would like to share my ideas, i'm new to angularjs and i'm so exited with what we could do.

I build something similar to your directive but unfurtunately i'm having some issues. i'm trying to create a custom upload application that display a preview of the file that is uploading and once it finish update the upload with the path of the file and a preview of them. but doesn't seems to work. 'cause i'm not able to update the array. 

By the way i'm trying that the parameters can be customize and not using fixed names like "files, queue" i'm using the attributes option to pass this names. 
Reply all
Reply to author
Forward
0 new messages