Support

Home Forums Event Espresso Premium Duplicate event meta with event

Duplicate event meta with event

Posted: June 24, 2016 at 2:57 pm


Chris

June 24, 2016 at 2:57 pm

My events are setup to use a more advanced layouts using Advanced Custom Fields. Since this info is saved to post meta it’s not being duplicated when my users are using the built in duplicate event button. Is there a way this can be done?


Tony

  • Support Staff

June 27, 2016 at 4:11 am

Hi Chris,

Which version of Event Espresso are you using please?


Chris

June 27, 2016 at 7:57 am

Hi Tony,
EE 4.9.1
WP 4.5.3

Thanks


Chris

June 27, 2016 at 9:01 am

ACF 5.3.9.1 if that matters


Josh

  • Support Staff

June 27, 2016 at 11:14 am

You should be able to use the

AHEE__Extend_Events_Admin_Page___duplicate_event__after

action hook to programmatically duplicate post meta fields and values from the original event onto the new, duplicate, event.


Chris

July 7, 2016 at 12:32 pm

HI Josh do you have an example of how this would be used? Is this something that will be supported in future updates?

thanks,
chris


Josh

  • Support Staff

July 7, 2016 at 12:39 pm

Code example wise, you can take a look at the _duplicate_event() method in EE4 core’s /caffeinated/admin/extend/events/Extend_Events_Admin_Page.core.php to see how the various items are duplicated.

We are not planning on changing the duplicate event feature to include event meta in a future update. The reason is because post meta data tends to be inconsistent.

The support post ‘Duplicate event meta with event’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso