Adding in .unwrap() support, thanks to Ben Alman! Fixes #5191.
This commit is contained in:
parent
70b9aed422
commit
69e6e53555
2 changed files with 39 additions and 0 deletions
|
@ -90,6 +90,14 @@ jQuery.fn.extend({
|
|||
});
|
||||
},
|
||||
|
||||
unwrap: function() {
|
||||
return this.parent().each(function(){
|
||||
if ( !jQuery.nodeName( this, "body" ) ) {
|
||||
jQuery( this ).replaceWith( this.childNodes );
|
||||
}
|
||||
}).end();
|
||||
},
|
||||
|
||||
append: function() {
|
||||
return this.domManip(arguments, true, function(elem){
|
||||
if ( this.nodeType === 1 ) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue