JavaScript Reference/Javascript Methods/createDocumentFragment
Версия от 18:30, 25 мая 2010; (обсуждение)
"createDocumentFragment()" Example
<html>
<body>
<script language="JavaScript">
function function1() {
var newDoc = document.createDocumentFragment();
newDoc.innerHTML = "<p>some text</p>";
alert(newDoc.innerHTML);
}
</script>
<input id="myT" type="button" value="Click me" onclick="function1();">
</body>
</html>
"createDocumentFragment()" is applied to
+----------------+--------------------------------------------------------------+
| Applied_To |document |
+----------------+--------------------------------------------------------------+
"createDocumentFragment()" Syntax, Parameters and Note
Note:
Creates a new document object.
Syntax:
document.createDocumentFragment()