I want to change color
of button-down
and button-up
when spinner
have min or max value to red
<input type="hidden" name="id" value="<?= $this->product->getId() ?>" />
<input name="quantity" value="1" readonly/>
<script type="text/javascript">
$(document).ready(function () {
$('input[name="quantity"]').spinner({
min: 1,
max: <?= $this->product->getQuantity() ?>,
}).keydown(function (e) {
e.preventDefault();
});
});
</script>
You can apply a
change
method which jquery ui spinner provides: