x
 
<!DOCTYPE html>
<html>
<body>
<h3>演示如何创建 QUOTE 元素</h3>
<p>点击按钮来创建引用来源为 wwf.org 的 QUOTE 元素。</p>
<button onclick="myFunction()">试一下</button>
<script>
function myFunction()
{
var x = document.createElement("QUOTE");
var t = document.createTextNode("Our goal is to build a future where people live in harmony with nature.");
x.setAttribute("cite", "http://www.wwf.org");
x.appendChild(t);
document.body.appendChild(x);
}
</script>
</body>
</html>