Is there any way to remove fields with definite in Jquery?
I have the following code via Javascript, when I make an Input recording the date in the database, I need the button and the input to disappear, only allowing the input date:
<td>
<?php echo $fetch['data_protocolo']; ?>
<br>
<br>
<input name="protocolo" id="protocolo" type="text" placeholder="" style="width:100px;font-size: 13px" class="form-control input-md">
<br>
<input id="btn" type="submit" class="btn btn-primary" value="OK" />
</td>
<script>
var btn = document.getElementById('btn');
btn.onclick = function () {
document.getElementById('protocolo').remove();
this.remove();
};
</script>
The code above works, but if I refresh the page, the buttons come back. Would there be any way to permanently remove the fields?