So im trying to make it so in my input which is maximised at 1000 and minimised at 0.10 basically change an element to the given output of the input then times it by 0.98
Here is what i have so far:
<div id="dicegame">
<div id="diceholder">
<h1>
<div id="diceroller">
<span id="value" class="lable_value">0</span>
</div>
</h1>
<h3>
<div class="winchance">1 - 6</div>
</h3>
</div>
<div id="inputholder">
<div id="input">
<div class="betamount">
<b>Gems to bet:</b>
</div>
<form class="input-money">
<b><input id="bet" onkeyup="edValueKeyPress()" type="number" name="bet" style="color: #404040;" class="form-control" min="0.10" step="any" max="1000.00" value="1.00"></b>
</form>
<div class="profitamount">
<b>Profit:<b>
</div>
<div id="profit">
</div>
<script>
var input = document.getElementsByClassName("form-control")
function myFunction()
{
x=document.getElementsByClassName("profit"); // Find the elements
for(var i = 0; i < x.length; i++){
x[i].ierText=input * 0.98; // Change the content
}
}
</script>
