Skip to main content

Bug Tracker

Side navigation

#5917 closed bug (fixed)

Opened January 24, 2010 03:09AM UTC

Closed February 02, 2010 02:54AM UTC

Last modified February 05, 2010 09:48PM UTC

replaceWith is not working as mentioned in the api doc

Reported by: neerajdotname Owned by:
Priority: major Milestone: 1.4.2
Component: manipulation Version: 1.4.1
Keywords: Cc:
Blocked by: Blocking:
Description

replaceWith is working fine when only one element is replaced.

When more than one elements are to be replaced then all the elements are replace with a single element.

<h2>one</h2>

<h2>two</h2>

<h2>three</h2>

$('h2').replaceWith('<span>lab</span>');

Above code will replace all the three h2 with a single span.

Attachments (0)
Change History (5)

Changed January 24, 2010 03:17AM UTC by neerajdotname comment:1

Changed January 24, 2010 03:47AM UTC by neerajdotname comment:2

Changed February 02, 2010 02:54AM UTC by john comment:3

component: unfilledcore
resolution: → fixed
status: newclosed

I added in the tests but they're all working.

http://github.com/jquery/jquery/commit/532bec4c694532acbe2e14ad3b6ff72a4da90be0

A previous commit must've fixed this!

Changed February 02, 2010 02:54AM UTC by john comment:4

milestone: 1.4.11.4.2
version: 1.41.4.1

Changed February 05, 2010 09:48PM UTC by john comment:5

component: coremanipulation