1、var domObj = $("<dom>");


2、var a = $("<a href='www.baidu.com'>");

3、alert(a.prop("outerHTML"));

//另外一种方法clone复制一份参数true表示同时复制事件

that.clone(true).prependTo(that.parent());
that.remove();

  

相关文章: