Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Fetching contributors…
Cannot retrieve contributors at this time
31 lines (31 sloc) 1.1 KB
<?xml version="1.0"?>
<entry type="method" name="unwrap" return="jQuery">
<desc>Remove the parents of the set of matched elements from the DOM, leaving the matched elements in their place.</desc>
<p>The <code>.unwrap()</code> method removes the element's parent. This is effectively the inverse of the <code><a href="/wrap">.wrap()</a></code> method. The matched elements (and their siblings, if any) replace their parents within the DOM structure.</p>
<desc>Wrap/unwrap a div around each of the paragraphs.</desc>
}, function(){
div { border: 2px solid blue; }
p { background:yellow; margin:4px; }
<category slug="manipulation/dom-insertion-around"/>
<category slug="manipulation/dom-removal"/>
<category slug="version/1.4"/>
Jump to Line
Something went wrong with that request. Please try again.