I have an input and would like that when clicking on Search or enter open a certain address adding the value of the input: Example
<form align="center" method="GET">
<input type="text" placeholder="Faça sua pergunta" autofocus name="query" size="50">
<input type="submit" onclick="myFunction()" value="Buscar">
</form>
<script>
function myFunction() {
var query = document.getElementsByName('query');
window.open("http://leituracrista.com/indice/?query=" + query.value);
}
</script>