The datepicker is not available after submitting a form that contains "image" fields.
1. I have a form with a title that is required, an image and a date.
2. I don't fill the form and submit it.
3. The form is displayed saying that I must fill in the title, and the datepicker is not available. That is because the required js files are not loaded.

Files are loaded in date_time_field_field_widget_form. This function is only executed when drupal_retreive_form is executed.
If the form is loaded from cache, drupal_retreive_form is not executed.
If you have a content type with: titlte, image and date fields, after submitting the form, it is retreived from cache (cache is found).
But if you have a content type with only title and date fields, the form is not found in the cache upon submitting it. The form is not saved in the cache_form table.

$form_state['cache'] is different in those 2 cases. That's why the second form is not saved.
The value is set in $form = form_builder($form_id, $form, $form_state); from drupal_process_form() function.

Comments

Jens Peter’s picture

I just installed this module and I don't get the datepicker either.
I use Drupal 7.10.
Guess I have to go to the other date picker module even if it would be handy only have this small one.

Jens Peter’s picture

Priority: Normal » Major
meladawy’s picture

Dear jenspeter,
Sorry for lag, but can you please explain briefly what is the problem u face .
please make sure that there is no Jquery Conflict
thanks

meladawy’s picture

Dear mfernea ,
im checking the issue right now , reply to u soon

thanks

Jens Peter’s picture

I installed the module and as it said on the module page I didn't do anything else.
Added the fields on the page where I needed it - I got the date option and it looked correctly..
When I made a new page where the fields were added and I got to the field nothing happened. No popup, no date select of any kind.
I did not get any error - not any I could see.

I have installed the other module now so this module is removed from the site as I had to get it to work this weekend.

flomar’s picture

Same Issue.
I installed the module and created a new content-type. I only see an empty text field instead of the Date picker when I want to create a new content.

meladawy’s picture

Hello flomar ,
Do u have image field in your form
thanks

videodoll’s picture

i needed to update jquery... my problem is fixed.

meladawy’s picture

Status: Active » Needs work

i fixed this in the new release..!

mfernea’s picture

Status: Needs work » Closed (fixed)

Then I think this can be closed.
Thank you!

mfernea’s picture

Issue summary: View changes

Add more details regarding what's happening in the background.