<html> <body> <script language="JavaScript"> function function1() { var m = document.all.myLink.urn; alert(m); } </script> <input type="button" value="Get the urn" onclick="function1();"> <a id="myLink" href=http://www.java2java.com/ urn="Java2s.com Website">Java2s.com web page</a> </body> </html>