Javascript - Does not save into database when i change value in javascript side <p>My code looks like this:</p> <pre> document.getElementById("medewerkers").value = mdwString; document.getElementById("medewerkersomschr").value = mdwNaam; $("#medewerkers").val(mdwString); $("#medewerkersomschr").val(mdwNaam); document.getElementById("machines").value = mchString; document.getElementById("machinesomschr").value = mchNaam; $("#machines").val(mchString); $("#machinesomschr").val(mchNaam); </pre> <p>As u can see i tried two ways to get a value into fields.</p> <p>This does work for me, but next up when i try to save the values into the database it goes wrong. It looks like the view got updated but not the value of the html itself. Does anyone have an idea what i am doing wrong or what i should change up?</p>