Skip to main content

Bug Tracker

Side navigation

#4105 closed bug (fixed)

Opened February 10, 2009 01:45PM UTC

Closed February 28, 2009 07:59PM UTC

clone(true) fails on IE7

Reported by: htoug Owned by:
Priority: major Milestone:
Component: core Version: 1.2.6
Keywords: clone Cc:
Blocked by: Blocking:
Description

I have a form, where part of the form is dynamic. The user can add field-sets and in each fieldset add one or more fields.

This is done by having a hidden prototype and a couple of buttons to add fields-sets and fields.

Everything work perfectly in FF3.

In IE7 I get a javascript error from the jQuery clone function when 'Add Fieldset' button is pressed. The error comes from the copying of events on the triggered field_add function call.

Debugging indicates that clone has fewer elements than this.find("*").andSelf().each() calls. In the included (reduced) example the error occurs in line 1824 with the variable 'i' having value 3 and clone having a length of 2. Therefore 'clone[i]' is undefined and the clone-call fails.

Chaning 'clone(true)' to 'clone()' removes the problem, but gives me the pain of having to reset all events at every addition.

Attachments (1)
  • custom1.html (2.1 KB) - added by htoug February 10, 2009 01:46PM UTC.

    Exmple of the error - reduced to 1 page.

Change History (2)

Changed February 12, 2009 04:15AM UTC by dmethvin comment:1

I think this may have been fixed along with #3500.

Changed February 28, 2009 07:59PM UTC by dmethvin comment:2

resolution: → fixed
status: newclosed

I'll close this as fixed, reopen with a test case if it's still in 1.3.2.