Code (javascript)
<html>
<head>
<script type="text/javascript">
function changeLink()
{
document.getElementById('myLink').innerHTML="WebSewak";
document.getElementById('myLink').href="http://www.websewak.com";
document.getElementById('myLink').target="_blank";
}
</script>
</head>
<body>
<a id="myLink" href="http://www.yah.in">Yah.in Collection</a>
<input type="button" onclick="changeLink()" value="Change link">
</body>
</html>
No comments:
Post a Comment