I'm looking for the solution : opening the Popup window by inserting a value for example.
if your site is: www.example.com/ by inserting a value as a text let's take ' results ' and clicking on the button show us this Popup page: www.example.com/results
actually I'm using this Code, but that shows the result in the same page
<!DOCTYPE html>
<html>
<head>
<title>Redirect url in Javascript</title>
</head>
<body>
<input id = "url" type = "text" name = "url"
placeholder = "Enter a url here">
<input type = "submit" name = "button" onclick = "fun()">
<script>
function fun() {
var url= document.getElementById("url").value;
document.write("Redirecting to the url in 3 seconds...");
setTimeout(function(){window.location = url;}, 3000);
}
</script>
</body>
</html>