Bug Tracker

Opened 7 years ago

Closed 7 years ago

#12667 closed bug (notabug)

html() crashes on SVG elements

Reported by: mjbecze@… Owned by:
Priority: undecided Milestone: None
Component: unfiled Version: 1.8.0
Keywords: Cc:
Blocked by: Blocking:

Description

For example

$("#svg_element").html();

results in

Uncaught TypeError: Cannot call method 'replace' of undefined

at line 5935

5935 elem.innerHTML.replace( rinlinejQuery, "" ) :

Change History (1)

comment:1 Changed 7 years ago by dmethvin

Resolution: notabug
Status: newclosed

SVG elements don't contain HTML, right? So asking for it is, well, asking for it. I don't think we should just return an empty string, since that would just mask the problem.

Note: See TracTickets for help on using tickets.