Currently I’m trying to edit a hidden form with the command:
jQuery(document).ready(function(){
jQuery("#test").val("hi");
});
This is inside an inline drupal_add_js.
When the form ‘test’ is a normal textfield, this works. When it is hidden, this does not work. I’m currently using Drupal 7’s webform module to create the form. I’ve read dozens of stackoverflow questions regarding populating hidden fields but I haven’t gotten anything to work. I’m hoping that its just something that is syntactically different for hidden fields, but most likely its something in drupal I don’t know about.
Try instead: