<td align="center" class="price-info" valign="top">Disponibles:<span style="display: inline;" id="product_inventory"> [stock]</span></td>
in that particular code, anyone know if when you are using product options, that span part is managed by ASP?, because when i use no options nothings is replaced, but when i do , no matter what i use between that label , is always replaced by the stock, is that the way ASP works, it changes the span label using the id with the data requested in this case the stock of the option?, because im trying to change some stuff, but keeps using the same valor....
to be more specific im using a script like this
stock = 10
the true part should be 10 but the else part should be 1.10 but no matter what i do with products with options it always prints 10 and if i inspect the code in chrome it show a new line of code just after </script> with this
<td align="center" class="price-info" valign="top">Disponibles:<span style="display: inline;" id="product_inventory"> 10 </span></td>
in that particular code, anyone know if when you are using product options, that span part is managed by ASP?, because when i use no options nothings is replaced, but when i do , no matter what i use between that label , is always replaced by the stock, is that the way ASP works, it changes the span label using the id with the data requested in this case the stock of the option?, because im trying to change some stuff, but keeps using the same valor....
to be more specific im using a script like this
stock = 10
Code:
<script> { var aux_stock = [stock] *1.10; if (something) { document.write('<td align="center" class="price-info" valign="top">Disponibles:<span style="display: inline;" id="product_inventory"> [stock]</span></td>'); } else { document.write('<td align="center" class="price-info" valign="top">Disponibles:<span style="display: inline;" id="product_inventory"> ' + aux_stock + '</span></td>'); } } </script>
<td align="center" class="price-info" valign="top">Disponibles:<span style="display: inline;" id="product_inventory"> 10 </span></td>
Comment