Uploaded 3 Select a file that does not work in ie9

I created a page with a loader. I use Uploadify 3 as the bootloader. The code works in all browsers except IE9. When I turn on IE 9 in compatibility mode, it works. In IE9, I cannot click the download button. It shows, but there is no response to a click. Thus, the file selection dialog does not open. In Opera, chrome and FF, the button works, and when I click, the file open dialog opens.

Flash works in IE9. (version 11,0,1,152) (youtube works)

When I press the button correctly, I do not receive flash information. When I do this in all other browsers, I get flash information. When I click on youtube (in ie9), I also get flash information ....?

This is my downloadable jquery code:

$(document).ready(function() { $('#fileInput').uploadify({ 'swf': '/Content/Scripts/uploadify3/uploadify.swf', 'uploader': '/nl-nl/Attachment/Upload', 'cancelImage': '/Content/Scripts/uploadify3/uploadify-cancel.png', 'checkExisting': '/nl-nl/Attachment/Check', 'multi': true, 'buttonText': 'Upload', 'postData' :{'RelationId' : '@cookie'}, 'sizeLimit': 2147483647, 'auto': true, onError: function(a, b, c, d) { if (d.status == 404) alert("Could not find upload script. Use a path relative to: " + "<?= getcwd() ?>"); else if (d.type === "HTTP") alert("error " + d.type + ": " + d.status); else if (d.type === "File Size") alert(c.name + " " + d.type + " Limit: " + Math.round(d.sizeLimit / 1024) + "KB"); else alert("error " + d.type + ": " + d.text); }, onUploadComplete: function() { $("#Grid").data('tGrid').ajaxRequest(); } }); }); 

I made a mistake? Is this a flash bug? Or something else?

+4
source share
2 answers

I don’t know the real problem, but for someone else with this problem. It works after deployment, and not in debug mode.

+2
source

It works when you replace swf with all the way

 http://www.uploadify.com/uploadify/uploadify.swf 

This is not an elegant solution, but it works. I have this problem only in localhost.

Now the select button works fine in IE, but we have a security bug. To solve the problem, you need to add the crossdomain.xml file to the root directory.

Example crossdomain.xml for all domains (test only)

 <?xml version="1.0"?> <!DOCTYPE cross-domain-policy SYSTEM "http://www.adobe.com/xml/dtds/cross-domain-policy.dtd"> <cross-domain-policy> <site-control permitted-cross-domain-policies="all"/> <allow-access-from domain="*" /> <allow-http-request-headers-from domain="*" headers="*"/> </cross-domain-policy> 

or try adding a line to the Global.asax file Add this line to the RegisterRoutes method

  routes.IgnoreRoute("crossdomain.xml"); 
+4
source

Source: https://habr.com/ru/post/1379922/


All Articles