<a onclick="m()" href="#">Click To View</a> <script> alert(document.title); function m() { document.write("<title>Harsh Tiwari</title><a href='#'>Click Here</a><scr" +"ipt type='text/javascript'>alert(document.title);</sc"+"ript >"); } </script>