Just take the “actual value” of the input. Make sure to remove any decimal dot…. Parse it as an integer and divide by 100. Return. 😉
document.querySelector(".detailsInput").addEventListener("input", function(e){
let actualValue = e.target.value.replace(".","")
e.target.value=parseInt(actualValue)/100
})
<input type=number min=0.00 max=100.00 step=0.01 class='detailsInput' id='priceEntry' name='priceEntry' placeholder='Enter Price'>
=== Ho! If you insist on an inline version:
<input type=number min=0.00 max=100.00 step=0.01 class='detailsInput' id='priceEntry' name='priceEntry' placeholder='Enter Price' oninput="this.value=parseInt(this.value.replace('.',''))/100">
CLICK HERE to find out more related problems solutions.