Good morning,
I'm trying to load a value into the Input after the user clicks the button.
// Este é o Botão
<button type="button" class="btn btn-default" tabindex="-1" onclick="id_host()"> Identificar Nome </button>
When he clicks this button, I want him to go to a page .php
and make a gethostname()
and return with the result, assigning in the input.
Follow the code for better understanding:
// Função quando Clicar no Botão.
function id_host() {
var n_pc = $("#conteudo").load("processa.php");
document.getElementById('#conteudo').value = n_pc;
}
This is the Input I want popular with the result of processa.php
<input type="text" class="form-control" name="conteudo" id="conteudo" value="">
Can anyone help me?
Thank you.