In a recently developed and published website, I ran into a problem with the scheduler module, which is driving me absolutely crazy. I'm hoping someone has experienced the same problem.
At node/add form I enter a publish and unpublish date. The scheduler format used is Y-m-d H:i:s
The dates are stored in the DB. Also the node will show up on the content > scheduled overview page.
So far so good.
Here's where the shit hits the fence. When editing this node the fields are empty. So when the user saves the node the stored values are overwritten by the empty fields. And the node won't be unpublished.
I'm using scheduler with date popup. But disabeling date popup and setting scheduler to a textfield hasn't had any results. When I take a var_dump of the value in scheduler_form_alter -> nodetype_form
$form['scheduler_settings']['publish_on'] = array( '#type' => 'textfield', '#title' => t('Publish on'), '#maxlength' => 25, '#required' => $publishing_required, '#default_value' => isset($defaults->publish_on) && $defaults->publish_on ? format_date($defaults->publish_on, 'custom', $internal_date_format) : 'test', '#description' => $description_format.$description_blank, ); }
The #default_value contains the correct date format. When I add #value to the form with the #default_value the fields are correct.
Can anybody help me why the #value of this fields stay empty?