Bug Tracker

Opened 12 years ago

Closed 11 years ago

Last modified 11 years ago

#10864 closed bug (fixed)

text() method on a document fragment always returns the empty string

Reported by: rockhymas Owned by: Rick Waldron
Priority: blocker Milestone: 1.7.2
Component: manipulation Version: 1.7
Keywords: Cc:
Blocked by: Blocking:

Description

The following code used to work in 1.6.x, but no longer does (1.7 or 1.7.1) See http://jsfiddle.net/9UcdC/ for repro. Just change the jquery version to 1.6 to see that it used to work.

frag = document.createDocumentFragment();
frag.appendChild(document.createTextNode('Always two there are'));

alert($(frag).text())

Change History (5)

comment:1 Changed 12 years ago by rockhymas

Submitted pull request with fix at https://github.com/jquery/sizzle/pull/84

comment:2 Changed 12 years ago by Timmy Willison

Component: unfiledmanipulation
Milestone: None1.7.2
Priority: undecidedhigh
Status: newopen

comment:3 Changed 11 years ago by Rick Waldron

Owner: set to Rick Waldron
Status: openassigned

comment:4 Changed 11 years ago by Rick Waldron

Priority: highblocker

comment:5 Changed 11 years ago by Rick Waldron

Resolution: fixed
Status: assignedclosed

Adds test to support Sizzle getText patch for document fragments. Fixes #10864.

Changeset: 499658970b2c9add7a7d175dffc8e263c3b7b50d

Note: See TracTickets for help on using tickets.