rortk1 / jquery-multifile-plugin

Automatically exported from code.google.com/p/jquery-multifile-plugin
0 stars 0 forks source link

Null in $ext when extension is e.g. 6-chars long #157

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Hi,

What steps will reproduce the problem?
1. Try to attach file with extension for example exeeee.
2. This extension is not on the list of acceptable extensions
3. You will get null value in error message with $ext value

What is the expected output? What do you see instead?

Expeteced output is exeee in $ext value.

What version of the plugin/jQuery are you using?
PLUGIN VERSION: 1.48
JQUERY VERSION: 1.7

On what browser(s) or operating system?
BROWSER(S): IE 8, firefox latest, Win Vista

Original issue reported on code.google.com by majk...@gmail.com on 2 Aug 2012 at 6:27

GoogleCodeExporter commented 8 years ago
I think it should look like this:

ERROR = MultiFile.STRING.denied.replace('$ext', String(v.match(/\.\w*$/gi)));

instead of 

ERROR = MultiFile.STRING.denied.replace('$ext', 
String(v.match(/\.\w{1,4}$/gi)));

You never know what files with what extensions people would like to upload :)))

Original comment by majk...@gmail.com on 2 Aug 2012 at 7:15