var reg = /^<.+>.+<.+>$/;
// console.log(reg.exec("<p class='demo'>hello icketang</p>"));
var str = "<p class='demo'>hello icketang</p>".replace(/^<.+>(.+)<.+>$/,function(match,$1){
return $1;
})
console.log(str);