Duplicate as different post type via API
-
Hi!
I’m currently using Toolset Types and have a bunch of different post types set up. I’m trying to work out how I can create posts by duplicating from a library of predefined posts. I.e. I select a post from a drop down list of previous created “templates” types duplicate it as a different post type. As an example, There are predesigned workout exercises (Squats, Plank, Burpees for example) as templates and I duplicate the Squat template as an “exercise” post type and add additional info like numbers of reps and sets.
Can you use the API and the “duplicate_post_pre_copy” action to mean that the duplicate that is made is actually as a different post type to the original?
Thanks!
- The topic ‘Duplicate as different post type via API’ is closed to new replies.