Title: Date and Time Picker Field
Author: Per Søderlind
Published: <strong>5 Aprile 2013</strong>
Last modified: 30 Gennaio 2017

---

Ricerca i plugin

![](https://ps.w.org/acf-field-date-time-picker/assets/banner-772x250.png?rev=703173)

Questo plugin **non è stato testato con le ultime 3 versioni principali (major releases)
di WordPress**. Potrebbe non essere più mantenuto, o supportato, e potrebbe presentare
problemi di compatibilità se utilizzato con versioni più recenti di WordPress.

![](https://ps.w.org/acf-field-date-time-picker/assets/icon-256x256.jpg?rev=996369)

# Date and Time Picker Field

 Di [Per Søderlind](https://profiles.wordpress.org/pers/)

[Scarica](https://downloads.wordpress.org/plugin/acf-field-date-time-picker.2.1.5.zip)

 * [Dettagli](https://it.wordpress.org/plugins/acf-field-date-time-picker/#description)
 * [Recensioni](https://it.wordpress.org/plugins/acf-field-date-time-picker/#reviews)
 *  [Installazione](https://it.wordpress.org/plugins/acf-field-date-time-picker/#installation)
 * [Sviluppo](https://it.wordpress.org/plugins/acf-field-date-time-picker/#developers)

 [Supporto](https://wordpress.org/support/plugin/acf-field-date-time-picker/)

## Descrizione

This is an add-on for the [Advanced Custom Fields](https://wordpress.org/extend/plugins/advanced-custom-fields/)
WordPress plugin, that allows you to add a Date and Time Picker field type.

**ACF PRO 5.0+ is no longer supported, ACF PRO [has its own date and time picker](https://www.advancedcustomfields.com/resources/date-time-picker/)**

#### Compatibility

This add-on will work with:

 * Advanced Custom Fields version 4._._
 * Advanced Custom Fields version 3 and bellow

#### Maggiori informazioni

[http://soderlind.no/time-picker-field-for-advanced-custom-fields/](http://soderlind.no/time-picker-field-for-advanced-custom-fields/)

## Screenshot

 * [[
 * Add the Date and Time Picker field
 * [[
 * Date and Time Picker
 * [[
 * Time Picker

## Installazione

#### Plugin

 1. Copy the ‘acf-date_time_picker’ folder into your plugins folder
 2. Activate the plugin via the Plugins admin page

#### Include

 1. Copy the ‘acf-date_time_picker’ folder into your theme folder (can use sub folders).
    You can place the folder anywhere inside the ‘wp-content’ directory
 2. Edit your functions.php file and add the code below (Make sure the path is correct
    to include the acf-date_time_picker.php file)
 3. add_action(‘acf/register_fields’, ‘my_register_fields’);
 4. function my_register_fields()
     { include_once(‘acf-date_time_picker/acf-date_time_picker.
    php’); }

## FAQ

  Installation Instructions

#### Plugin

 1. Copy the ‘acf-date_time_picker’ folder into your plugins folder
 2. Activate the plugin via the Plugins admin page

#### Include

 1. Copy the ‘acf-date_time_picker’ folder into your theme folder (can use sub folders).
    You can place the folder anywhere inside the ‘wp-content’ directory
 2. Edit your functions.php file and add the code below (Make sure the path is correct
    to include the acf-date_time_picker.php file)
 3. add_action(‘acf/register_fields’, ‘my_register_fields’);
 4. function my_register_fields()
     { include_once(‘acf-date_time_picker/acf-date_time_picker.
    php’); }

  Updating to ACF PRO

I got this quetion over at [AWP on Facebook](https://www.facebook.com/groups/advancedwp/permalink/1198240376904841/?comment_id=1198432300218982&notif_t=group_comment&notif_id=1469033404164280):

    ```
    How does upgrading work? If someone starts with ACF and your plugin,
    then upgrades to ACF Pro, will their date/time custom field disappear?
    I understand the data will be maintained but wondering if the field
    will still be visible in WP admin.
    ```

Updating to ACF PRO should work fine, ACF PRO has a compatibility add-on for this
plugin, but test it on a non production environment first.

Also, read the comments on this issue: [https://github.com/…/acf-field-date-time-picker/issues/103](https://github.com/.../acf-field-date-time-picker/issues/103)

  How do I set the date and time format?

To set the date and time format when you create the field, you have to create a 
string using the letters below.

  Date format

d day of month (no leading zero)
 dd day of month (two digit) o day of the year (
no leading zeros) oo day of the year (three digit) D day name short DD day name 
long m month of year (no leading zero) mm month of year (two digit) M month name
short MM month name long y year (two digit) yy year (four digit)

  Time format

H Hour with no leading 0 (24 hour)
 HH Hour with leading 0 (24 hour) h Hour with
no leading 0 (12 hour) hh Hour with leading 0 (12 hour) m Minute with no leading
0 mm Minute with leading 0 s Second with no leading 0 ss Second with leading 0 l
Milliseconds always with leading 0 t a or p for AM/PM T A or P for AM/PM tt am or
pm for AM/PM TT AM or PM for AM/PM

  Examples

 * `yy-mm-dd`: 2013-04-12
 * `HH:mm`: 24 hour clock, with a leading 0 for hour and minute
 * `h:m tt`: 12 hour clock with am/pm, no leading 0

**How do I format the date and time when I want to use it in my theme?**

The Date and Time Picker field is saved as an UNIX timestamp. Use the PHP [date](http://php.net/manual/en/function.date.php)
function when you use it in your theme.

## Recensioni

![](https://secure.gravatar.com/avatar/040afa1c95dbb3a9169c1f9488e33134f3b44523689f40938930fb41a68c38cb?
s=60&d=retro&r=g)

### 󠀁[Not as per the demo given](https://wordpress.org/support/topic/not-as-per-the-demo-given/)󠁿

 [pradeep4net](https://profiles.wordpress.org/pradeep4net/) 20 Settembre 2018

It only allows selecting the date, not time. take time automatically 12:00 AM. Doesn’t
work.

![](https://secure.gravatar.com/avatar/7d857f68161054f3a85b5d57a267c780fa80848bbe0888ed52411e5a276090e9?
s=60&d=retro&r=g)

### 󠀁[Works great showing date and time](https://wordpress.org/support/topic/works-great-showing-date-and-time/)󠁿

 [wp_ntnguy](https://profiles.wordpress.org/wp_ntnguy/) 2 Aprile 2017

This plugin works great. It allows admins to select date and time. This plugin should
have been included with the ACF core.

![](https://secure.gravatar.com/avatar/5c042bcb45837fafee6029f6bfac870d1b38304d4739e8ee572308d1be8854d4?
s=60&d=retro&r=g)

### 󠀁[Cumbersome not mobile friendly](https://wordpress.org/support/topic/cumbersome-not-mobile-friendly/)󠁿

 [eddiebt](https://profiles.wordpress.org/eddiebt/) 28 Febbraio 2017

Functionality on desktop is fine but poor on mobile devices. Doesn’t function correctly
in Contact 7. Kept being asked did I want to leave the page after saving. Affects
other pages using datepicker.

![](https://secure.gravatar.com/avatar/fb690b000ea3879024b9fbe1e802ad2ef3e082e5271f55ca05d8b545e3f61a85?
s=60&d=retro&r=g)

### 󠀁[great plugin](https://wordpress.org/support/topic/great-plugin-10412/)󠁿

 [erez_lieberman](https://profiles.wordpress.org/erez_lieberman/) 3 Settembre 2016

great plugin

![](https://secure.gravatar.com/avatar/594b19d0236e96b788d410adc50273ef86f70de58f42c0a9a1ca3a9622dc0eb9?
s=60&d=retro&r=g)

### 󠀁[working fine](https://wordpress.org/support/topic/working-fine-68/)󠁿

 [Mahfuzul Hasan](https://profiles.wordpress.org/mahfuzul/) 3 Settembre 2016

Helpful plugin

![](https://secure.gravatar.com/avatar/e2afcb7296e3a350cf8eb7a2d1582b4a59b55301d8a75c66b616ff1aaf782769?
s=60&d=retro&r=g)

### 󠀁[It works with ACF](https://wordpress.org/support/topic/it-works-with-acf/)󠁿

 [timbouchard](https://profiles.wordpress.org/timbouchard/) 3 Settembre 2016

Works Perfectly. The timestamp option is great.

 [ Leggi tutte le recensioni di 15 ](https://wordpress.org/support/plugin/acf-field-date-time-picker/reviews/)

## Contributi e sviluppo

“Date and Time Picker Field” è un software open source. Le persone che hanno contribuito
allo sviluppo di questo plugin sono indicate di seguito.

Collaboratori

 *   [ Per Søderlind ](https://profiles.wordpress.org/pers/)

“Date and Time Picker Field” è stato tradotto in 4 lingue. Grazie a [chi traduce](https://translate.wordpress.org/projects/wp-plugins/acf-field-date-time-picker/contributors)
per il contributo.

[Traduci “Date and Time Picker Field” nella tua lingua.](https://translate.wordpress.org/projects/wp-plugins/acf-field-date-time-picker)

### Ti interessa lo sviluppo?

[Esplora il codice](https://plugins.trac.wordpress.org/browser/acf-field-date-time-picker/)
segui il [repository SVN](https://plugins.svn.wordpress.org/acf-field-date-time-picker/),
segui il [log delle modifiche](https://plugins.trac.wordpress.org/log/acf-field-date-time-picker/)
tramite [RSS](https://plugins.trac.wordpress.org/log/acf-field-date-time-picker/?limit=100&mode=stop_on_copy&format=rss).

## Changelog

#### 2.1.5

 * Remove call to write_log() causing fatal error.

#### 2.1.4

 * Fix for English Canadian locale which became Catalan, also fixes other en_*, 
   fr_* and de_* locale.

#### 2.1.3

 * Sorry, but 2.1.2 had unfinsihed code, please update to 2.1.3

#### 2.1.2

 * Tested & found compatible with WP 4.7.

#### 2.1.1

 * Tested & found compatible with WP 4.6.

#### 2.1.0

 * ACF PRO 5.0+ is no longer supported, ACF PRO [has its own date and time picker](https://www.advancedcustomfields.com/resources/date-time-picker/)
 * Update plugin to WPCS standards.

#### 2.0.18

 * Thanks to [kamilgrzegorczyk](https://github.com/kamilgrzegorczyk), Fixing clone
   field issue in repeater

#### 2.0.17

 * Thanks to [leocaseiro](https://github.com/leocaseiro), Fix Backend Timestamp 
   handling: `render_field` and Tested Up WordPress 4.0

#### 2.0.16

 * Fix Undefined property: acf_field_date_time_picker::$domain

#### 2.0.15

 * Thanks to [yanknudtskov](https://github.com/yanknudtskov), the plugin now works
   with ACF 5.0

#### 2.0.14

 * Added new languages/acf-field-date-time-picker.po file (note, renamed the language
   file)

#### 2.0.13

 * Fixed compatibility bug with ACF 4.3.5
 * NOTE: 2.0.13 requires ACF 4.3.5 or later

#### 2.0.12

 * Added support for date format dd/mm/yy
 * Bugfix

#### 2.0.11

 * Added option to retrive field values, using the_field() and get_field(), as a
   timestamp

#### 2.0.10

 * Removed “value” from defaults

#### 2.0.9

 * Thanks to [flahertydaf](http://support.advancedcustomfields.com/forums/topic/custom-fields-get-emptied-when-publishing/page/2/#post-2325),
   the plugin in now working with the latest ACF version
 * Replaced DateTime::createFromFormat (PHP 5 >= 5.3.0), with strtotime
 * minor bugfixes

#### 2.0.8

 * Adds option to store the date and time field as a UNIX timestamp or not.

#### 2.0.7

 * Bug fix. 2.0.6 assumed that the stored date and time was in UNIX timestamp format.
   2.0.7 will check and only convert if the date and time is.

#### 2.0.6

 * Changed how the Date and Time Picker field is triggered when ACF adds a new Date
   and Time Picker field to the DOM
 * Saves the Date and Time Picker field as an UNIX timestamp to MySQL. Use the PHP
   [date](http://php.net/manual/en/function.date.php) function when you use it in
   your theme.

#### 2.0.5

 * When enqueuing JavaScripts, replaced dependecy of jquery-ui-datepicker with acf-
   datepicker

#### 2.0.4

 * Updated JavaScript [language detection and loading](http://soderlind.no/time-picker-field-for-advanced-custom-fields/#localization)

#### 2.0.3

 * Fixed Repeater field bug
 * Added support for including the field in a theme

#### 2.0.2

 * Updated readme.txt

#### 2.0.1

 * Minor fix

#### 2.0.0.beta

 * Total rewrite, based on the [acf-field-type-template](https://github.com/elliotcondon/acf-field-type-template).
   Works with ACF v3 and ACF v4. In this beta you can only add the Date Time Picker
   field as a plugin (i.e. not as a template field).

#### 1.2.0

 * Updated jquery-ui-timepicker-addon.js to the latest version (1.0.0) and added
   localization support.

#### 1.1.1

 * Fixed a small bug

#### 1.1

 * Change name to Date and Time Picker to reflect the new option to select between
   Date and Time picker or Time Picker only. Thanks to Wilfrid for point this out(
   not sure why I didn’t include it in 1.0)

#### 1.0

 * Initial version

## Meta

 *  Versione **2.1.5**
 *  Ultimo aggiornamento **8 anni fa**
 *  Installazioni attive **5.000+**
 *  Versione WordPress ** 3.6 o superiore **
 *  Testato fino alla versione **4.7.33**
 *  Lingue
 * [English (Canada)](https://en-ca.wordpress.org/plugins/acf-field-date-time-picker/),
   [English (US)](https://wordpress.org/plugins/acf-field-date-time-picker/), [Icelandic](https://is.wordpress.org/plugins/acf-field-date-time-picker/),
   [Spanish (Chile)](https://cl.wordpress.org/plugins/acf-field-date-time-picker/),
   e [Spanish (Spain)](https://es.wordpress.org/plugins/acf-field-date-time-picker/).
 *  [Traduci nella tua lingua](https://translate.wordpress.org/projects/wp-plugins/acf-field-date-time-picker)
 * Tag
 * [acf](https://it.wordpress.org/plugins/tags/acf/)[custom field](https://it.wordpress.org/plugins/tags/custom-field/)
   [datepicker](https://it.wordpress.org/plugins/tags/datepicker/)[timepicker](https://it.wordpress.org/plugins/tags/timepicker/)
 *  [Visualizzazione avanzata](https://it.wordpress.org/plugins/acf-field-date-time-picker/advanced/)

## Valutazioni

 3.7 su 5 stelle.

 *  [  8 recensioni a 5-stelle     ](https://wordpress.org/support/plugin/acf-field-date-time-picker/reviews/?filter=5)
 *  [  2 recensioni a 4-stelle     ](https://wordpress.org/support/plugin/acf-field-date-time-picker/reviews/?filter=4)
 *  [  1 3- recensioni a stelle     ](https://wordpress.org/support/plugin/acf-field-date-time-picker/reviews/?filter=3)
 *  [  1 2- recensioni a stelle     ](https://wordpress.org/support/plugin/acf-field-date-time-picker/reviews/?filter=2)
 *  [  3 recensioni a 1-stelle     ](https://wordpress.org/support/plugin/acf-field-date-time-picker/reviews/?filter=1)

[Your review](https://wordpress.org/support/plugin/acf-field-date-time-picker/reviews/#new-post)

[Vedi tutte le recensioni](https://wordpress.org/support/plugin/acf-field-date-time-picker/reviews/)

## Collaboratori

 *   [ Per Søderlind ](https://profiles.wordpress.org/pers/)

## Supporto

Hai qualcosa da dire? Ti serve aiuto?

 [Chiedi nel forum di supporto](https://wordpress.org/support/plugin/acf-field-date-time-picker/)

## Donazioni

Vuoi sostenere le versioni future?

 [ Fai una donazione per lo sviluppo ](http://soderlind.no/donate/)