I have this line of code:
<input type="text" class="form-control" id="usado" placeholder="Quantidade" aria-describedby="basic-addon1">
<span class="input-group-addon" id="basic-addon1" onclick="usaEstoque(usado,<?php echo $arrDados['produto']; ?>)"><span class="glyphicon glyphicon-fire"></span></span>
I'm trying to get the value of the input and the value of the product id (this working on other buttons) in order to get the amount put into the input of the stock. In general, I'm trying to update the stock on the page itself.
I created the function in javascript to test:
function usaEstoque(usado,id){
var qtdUsado = usado;
var idProduto = id;
alert(qtdUsado, idProduto)
};