I have a form, automatically generated by a content type. I want to run a form_submit function to input/change some data to get saved in the database.
The content-type already has these fields setup, but I want them to be determined in a form_submit function rather than via user input.
I can get a form submit function, but I don't know how to add to the array of values being submitted without having to write the whole query myself. What variables do I need to grab and how to alter them to do this?
To be more specific.. in the form_alter, this does what I want.
$form["field_org_id"]["und"]['value']['#default_value'] = $org->id;
But how do I do the equivalent out of site in the form_submit? (this is a content-add form and hoping not to rewrite the entire query)