Home > Net >  Drupal 8 form value not changing with javascript
Drupal 8 form value not changing with javascript

Time:05-03

I have a drupal form, which contains a title, username, email, ... and I want the user to be able to insert some values and submit the data. My problem now is that when submitting the form my values are unchanged. Currently I am loading the data in with javascript:

document.getElementById("response").value = JSON.stringify(dataToSend);

The weird thing is that I see the value being changed but not when submitted. This is how my form field currently looks like: drupal form

When submit is pressed the passed value will remain response_placeholder Anybody that can help me?

CodePudding user response:

SOLVED: remove the #disable: true line

  • Related