I created a script to enable and disable fields on my page but they are not running.
$(document).ready(function() {
$("#EditarDados").click(function() {
// habilita o campo
$("nome").prop("disabled", false);
});
$("#SalvarDados").click(function() {
// desabilita o campo
$("nome").prop("disabled", true);
});
});
<button class="btn blue center-align" name="Salvar" id="SalvarDados">Salvar</button>
<button class="btn blue center-align" name="EditarDados" id="EditarDados">Editar Dados</button>
<input id="nome" name="nome" value="<?php echo $result['nm_nome'] ?>" type="text" disabled>