soderlind / acf-field-date-time-picker

Date and Time Picker field for Advanced Custom Fields v3 and v4
GNU General Public License v2.0
65 stars 27 forks source link

Re-adding support for ACF PRO #106

Open soderlind opened 8 years ago

soderlind commented 8 years ago

Ref dialog in WordPress Support Forum, could you please test the beta plugin below ?

NOTE, it:

The beta plugin is available in my dropbox

To stop ACF PRO from loading its date+time and time picker, I've added the following code to my plugin:

add_action( 'init', function() {
    class acf_field_date_and_time_picker { /* empty class, will prevent ACF Pro from creating it */} // @codingStandardsIgnoreLine
    class acf_field_time_picker{/* empty class, will prevent ACF Pro from creating it */} // @codingStandardsIgnoreLine
}, 1 );
andcam commented 8 years ago

thanks Per, will do. very much appreciated!

andcam commented 8 years ago

unfortunately it's throwing a JS error in console and the field boxes are missing:

"acf-input.min.js:1 Uncaught TypeError: Cannot read property 'date_format' of undefined"

Which i'm guessing means their JS is conflicting?

(ACF Pro v5.3.10)

soderlind commented 8 years ago

Yepp, I'll see if I can dequeue unneeded javascript(s).

soderlind commented 8 years ago

I need help.

How can I, from my plugin, remove/disable the following?: https://github.com/wp-premium/advanced-custom-fields-pro/blob/1f098799a2862c4d8272ce6809981f4048beaa5e/assets/js/acf-input.js#L4230-L4402