I have a problem here with Jquery, when the button is clicked I need to get the value of the input and replace the 'href' attribute of one and at the same time click on it ... I'm not having results, I can do the part of overriding the value of the attribute, but I can not do the click event right after!
btnContacts = button
contactParams = input text
sendContact = Tag A
NOTE: this is not a FORM!
$(document).ready( function () {
$('#btnContatos').click( function () {
var contato = $('#contatoParams').val()
//alert(contato)
$('#enviaContato').attr('href', '/chat/busca/'+contato);
// Mexer...
})
}