kingthebadger
Newbie
- Joined
- Jun 25, 2004
- Messages
- 1,536
- Reaction score
- 0
Basically i want people to enter any url (like an address bar) and click Go! to visit the url they have typed in. can someone give me the information to input this onto my site?
ve tried the following :
<html>
<head>
<script type="text/javascript" language="JavaScript">
<!--
function GoToURL() {
var URLis;
URLis = document.myForm.Dest.value
if (URLis == "" || URLis.length <= 8)
{
alert('\nOops!\n\nYou must enter a valid URL');
}
else
{
this.location.href = URLis;
}
}
//-->
</script>
</head>
<body>
<form name="myForm">
<input type="text" value="http://www." name="Dest">
<input type="button" value="go to url" onClick="GoToURL()">
</form>
</body>
</html>
ve tried the following :
<html>
<head>
<script type="text/javascript" language="JavaScript">
<!--
function GoToURL() {
var URLis;
URLis = document.myForm.Dest.value
if (URLis == "" || URLis.length <= 8)
{
alert('\nOops!\n\nYou must enter a valid URL');
}
else
{
this.location.href = URLis;
}
}
//-->
</script>
</head>
<body>
<form name="myForm">
<input type="text" value="http://www." name="Dest">
<input type="button" value="go to url" onClick="GoToURL()">
</form>
</body>
</html>