Welcome Guest, Not a member yet? Register   Sign In
Multiple file upload inside a form
#1

[eluser]megabyte[/eluser]
OK, so let me further explain so it doesn't sound so obviously simple.

I have a form in a cms, and I want to allow the user to upload multiple files.

I'd like to use flash, but every time I read about it I hear it needs a certain Flash version, and people have struggled to get it working with CodeIgniter.

So what I'm thinking about is using an iframe technique, but havent been able to find one I understand. I don't understand why you couldn't just put the entire upload inside the iframe instead of just posting to it.

Has anyone found a great solution? Implemented one?
#2

[eluser]Craig300[/eluser]
The way I did it was to have 5 (or how ever many files you wish to upload) file upload boxes with different names eg. file1, file2, file3, file4, file5 then iterate through a for loop on the other end with the file uploading code inside.

Hope this helps.

Craig
#3

[eluser]leonardteo[/eluser]
The most "straightforward" solution that I have come across is swfupload (Flash) http://www.swfupload.org/.

Flash version is not an issue (your posting is the first I've heard of that).

I had no issue with getting it to work with CodeIgniter. All of my issues were from debugging Javascript and I was new to Ajax at the time of implementation. You just need to know Javascript and Ajax enough to implement it properly. I suggest coupling it with the JQuery framework to make DOM selection easier. Javascript itself can be quite painful to debug, and I think that's where most people's implementations problems stem from. On the CI front, it's very straightforward in terms of handling POST uploads as it's the same as handling a single image (it just runs the script multiple times).

L.
#4

[eluser]permanentbraindamage[/eluser]
All these flash uploaders are flawed in that they are not able to use the cookies set by CI. I tried forcing the flash uploaders to set the cookies in the the http request headers. Real pain in the ass trying to get the session library to work with these flash uploaders.




Theme © iAndrew 2016 - Forum software by © MyBB