function getHTML(element) {
	  var wrapper = document.createElement('div');
	  wrapper.appendChild(element);
	  return wrapper.innerHTML;
	}
function getHTML(element) {
	  var wrapper = document.createElement('div');
	  wrapper.appendChild(element);
	  return wrapper.innerHTML;
	}
function getHTML ( element ) { var wrapper = document . createElement ( 'div' ) ; wrapper . appendChild ( element ) ; return wrapper . innerHTML ; }
Like outerHTML, but also works for DocumentFragment
Like outerHTML but also works for DocumentFragment