Javascript examples for DOM HTML Element:Input Button
Take a link from a user to use as button link
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <script type="text/javascript"> window.onload=function(){/* w w w . j a v a 2 s .c o m*/ var SiteURL = ''; SiteURL = 'http://java2s.com'; document.getElementById("a").href=SiteURL; } </script> </head> <body> <a href="linkofuser" id="a" >test</a> </body> </html>