Commit 6cb2e0b2 by Julian Arni

Check extension rather than mimetype

parent cee44501
...@@ -72,7 +72,7 @@ $('#fileupload').fileupload({ ...@@ -72,7 +72,7 @@ $('#fileupload').fileupload({
add: function(e, data) { add: function(e, data) {
submitBtn.unbind('click'); submitBtn.unbind('click');
var file = data.files[0]; var file = data.files[0];
if (file.type == "application/x-gzip") { if (file.name.match(/tar\.gz$/)) {
submitBtn.click(function(e){ submitBtn.click(function(e){
e.preventDefault(); e.preventDefault();
submitBtn.hide(); submitBtn.hide();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment