I'm using hook_form_alter
to modify an admin edit node screen. The form has a datetime field which I'm unable to get the value for in the render array. textfields value usually appears in value->#default_value.
xxx_form_alter(&$form, &$form_state, $form_id) {
print(json_encode($form['field_date_test']['widget']));
}
When the page loads, the value is in the input field but I can't find where I can get hold of the value before the page loads.