My Blog

Posts Tagged ‘Multiple File Upload plugin’

Multiple File Upload plugin for jQuery and IE7 and jQuery validation form

Wednesday, May 14th, 2008

All of you, maybe, know about this super Multiple File Upload. But when I start use it I have a strange things in IE7. I know it you could see it on the plugin website. (Select one file and the set focus again to this field or just try to upload another file).

bug

 

So have I fix this bug.

1. open jquery.MultiFile.js some with editors

2. after

        /// now let’s use jQuery
        slave = $(slave);

insert  this

        slave.attr("name",(slave.name || $(MASTER).attr(’name’) || ‘file’));
        slave.attr("id",(slave.id || MASTER.generateID(slave.i)));
        slave.val(”);
        slave.focus();

3. change

        // Remove element, remove label, point to current
                                        if(slave.i==0){
                                            $(MASTER.eCur).remove();
           MASTER.eCur = slave;
                                        }
                                        else{
                                            $(slave).remove();
                                        };

to

$(slave).remove();

 4. Thats all!

Now problem with jQuery validation plugin.

If you have a error message about that you should enter data less or equal some number.  You should replace all ".max" to ".maximum". Thats all too.

It was very helpful for me, so I hope it will be helpful for you!. If you have any question just ask me.