<html>
<body>
<p>Click the button to create an EMBED element with an embedded flash animation.</p>
<button onclick="myFunction()">Try it</button>
<script>
function myFunction() {
var x = document.createElement("EMBED");
x.setAttribute("src", "helloworld.swf");
document.body.appendChild(x);
}
</script>
</body>
</html>