I have a website with some buttons. When you click the buttons, they are directed to the respective pages, but there is a button that does not address, it only remains on the same page. The code I'm using for it is:
$('#btnSeguroViagem').on("click",function()
{
var novaURL = "seguro-viagem.php";
$(window.document.location).attr('href',novaURL);
});
<button type="submit" name="Submit" id="btnSeguroViagem" value="Solicitar" class="btn btn-danger btn-small"><i class="fa fa-plus-square"></i> Solicitar Seguro Viagem</button>
Can anyone tell me why this guy is not going? The page exists, I removed all the content and I put a sentence, but nothing. Clicking the button gives the post but stays on the same page and does not point to the secure-travelpage.php. The strange thing is that I already gave an alert () inside the call and arrives correctly.