Hi guys,
I want to assign something into label via JS but code below doesn't work for array. Do I miss something?
Thanks in advance
<script>
function calculate_cost(whichlabel){
document.getElementById('text_cost['+whichlabel+']').innerHTML = 'show me in label below';
}
<input type="text" name="text_qty[]" value="0" size="3" maxlength="5" style="text-align:center;" onkeyup="calculate_cost(0)" />
<label id="text_cost[]">0.00</label>