Date Picker not working on mobile

The date picker is supposed to automatically put in today’s date. It works on desktop, but not mobile. Any suggestions? Here’s the form:

This is the code I put in the functions.php file:

add_filter( ‘gform_field_value_current_date’, ‘populate_current_date’ );
function populate_current_date( $value ) {
$local_timestamp = GFCommon::get_local_timestamp( time() );
return date_i18n( ‘m/d/Y’, $local_timestamp, true );

I also tried it just using the merge tag without the code. Still doesn’t work on mobile.

Any ideas why it doesn’t work on mobile? Thank you!

Hi Jeanne. When I loaded the phone in Firefox on an iPhone I see the date pre-populated with 10/30/2020. How is that getting in there?


It defaults to the last day the form was saved.

Is that intentional? I thought you were trying to populate it with code, but you are saying it is populated with the date the form was last saved?

That happened for me on Desktop and Mobile.

No, I want it to be the date they fill out the form. It was working for me on desktop, but not on mobile. It’s not work for you on both?

I tried it with the merge tag and with code that I found on the forums.

It is adding that date on desktop and mobile. Gravity Forms does not do it on its own, so I am not sure how that is happening.

I recommend opening a support ticket for the issue:

okay, thanks!