Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Ticket #11126 (closed defect: fixed)

Opened 3 months ago

Last modified 5 days ago

[PATCH] [TEST] #writeAttribute('encType', 'multipart/form-data') doesn't work in IE

Reported by: NoiseEee Assigned to: kangax
Priority: normal Milestone:
Component: Prototype Version:
Severity: normal Keywords:
Cc:

Description

A documented FORM bug with IE regarding setting "enctype" on the fly http://verens.com/archives/2005/07/06/ie-bugs-dynamically-creating-form-elements/ happens with dynamically created FORM elements in Prototype 1.6.

For example, the following code...

var theForm = new Element('form', { id:'myFormID',name:'myFormName',method:'post',action:'myPage.php',enctype:'multipart/form-data'});

... does NOT actually produce a form with the equivalent of "enctype='multipart/form-data'" . IE requires an additional "encoding" parameter to achieve the proper form encoding:

var theForm = new Element('form', { id:'myFormID',name:'myFormName',method:'post',action:'myPage.php',encoding:'multipart/form-data',enctype:'multipart/form-data'});

Attachments

0002-Fix-writeAttribute-not-setting-encType-in-IE.-Closes.patch (1.3 kB) - added by kangax on 03/30/08 20:35:49.

Change History

02/15/08 15:13:49 changed by NoiseEee

This behaviour was discussed in efnet #prototype, and the user '@tobie' requested that a bug ticket be opened regarding this matter.

03/30/08 20:20:01 changed by kangax

  • summary changed from IE Ignores Encoding On Dynamically Created Forms to #writeAttribute('encType', 'multipart/form-data') doesn't work in IE.

03/30/08 20:35:27 changed by kangax

  • summary changed from #writeAttribute('encType', 'multipart/form-data') doesn't work in IE to [PATCH] [TEST] #writeAttribute('encType', 'multipart/form-data') doesn't work in IE.

03/30/08 20:35:49 changed by kangax

  • attachment 0002-Fix-writeAttribute-not-setting-encType-in-IE.-Closes.patch added.

03/30/08 20:48:47 changed by kangax

03/30/08 21:55:53 changed by kangax

  • owner changed from sam to kangax.

05/07/08 19:14:30 changed by jdalton

  • status changed from new to closed.
  • resolution set to fixed.