HTML Tutorial
TYPE DE RELATION
NOMBRE DE CONNAISSANCES

FAMILLE

Ami(e)s

PROFESSIONNELLE(S)

TOTAL COMMISSION
var input = document.getElementById('my-text-box') var input1 = document.getElementById('my-text-box1') var input2 = document.getElementById('my-text-box2') var messages = document.querySelector('#messages'); var messages3 = document.querySelector('#messages3'); $(document).ready(function () { input.addEventListener("input", function(e) { if (parseInt($(this).data('old-value')) < parseInt($(this).val())) { step_up(); } else { step_down(); } $(this).data('old-value', $(this).val()); }) input1.addEventListener("input", function(e) { if (parseInt($(this).data('old-value')) < parseInt($(this).val())) { step_up(); } else { step_down(); } $(this).data('old-value', $(this).val()); }) input2.addEventListener("input", function(e) { if (parseInt($(this).data('old-value')) 0 ?((t - 1) * 100) + base:0; var resF = valMessage3 + (res10 > 3000 ? 3000 : res10); messages3.value = resF; } function step_down(){ var valMessage3 = parseInt(messages3.value == "" ? 0 : messages3.value); var t = parseInt(input.value)+parseInt(input1.value)+parseInt(input2.value); var res10 =t >=0 ?(t * 100) + base:0; var resF = valMessage3 - (res10 > 3000 ? 3000 : res10); console.log(valMessage3,res10,resF) messages3.value = resF; } .Am{ font-size: 21px; font-family: fantasy; color: black; } .title{ font-size: 27px; font-family: fantasy; color: #00000094; } #my-text-box2,#my-text-box1,#my-text-box,#messages,#messages1,#messages2 ,#messages3{ height: 54px; font-size: 28px; text-align: center; /* font-weight: bold; */ font-family: fantasy; color: #ce0000; background-color: #21222300; border: 1px solid #00000038; } .divAm{ vertical-align: middle; */: ; height: 56px; line-height: 50px; /* text-align: right; */ /* border: 2px dashed #f69c55; */ padding-left: 10px; padding-right: 10px; border: 1px solid #cecece; } .title1{ height: 54px; font-size: 28px; text-align: center; /* font-weight: bold; */ font-family: fantasy; background-color: #21222300; border: 1px solid #00000038; } input[type=number]::-webkit-inner-spin-button { opacity: 1; background-color: red; color:red; }