Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
5.1.0.5
-
None
Description
When injecting an upload component via form injector, it tries to set the enctype of the form to "multipart/form-data". This works ok on most browsers, but as expected, IE doesn't like it... IE still sends the POST request as "application/x-www-form-urlencoded".
Nevertheless, there is a workaround (http://www.bennadel.com/blog/1273-Setting-Form-EncType-Dynamically-To-Multipart-Form-Data-In-IE-Internet-Explorer-.htm) that is to set not only the enctype but also the encoding of the form, which IE uses when submiting the form.
In practice, it only requires to change upload.js to something like this:
Tapestry.Initializer.injectedUpload = function(element)
{
var form = $(element).form;
form.enctype = "multipart/form-data";
form.encoding = "multipart/form-data";
}