Html page:
<button onclick="myFunction()">Try it</button>
Javascript page:
<script>
function myFunction() {
var txt = "Chapter
10";
txt.anchor("chap10");
alert(txt.anchor("chap10"));
}
</script>
Output:
<a name="chap10">Chapter 10</a>
No comments:
Post a Comment