Last active
March 8, 2017 23:54
-
-
Save lschatzkin/5666496 to your computer and use it in GitHub Desktop.
How to Change a Custom Post Type from one Custom Post Category to Another
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Example: | |
To move custom posts from Activity to Explore the Area (in this case, Airports, Transportation): | |
- wp3p_posts: get the ID for an example custom post (ex. 430) | |
change palms_activity to palms_explore for each post that needs to be moved | |
- wp3p_term_relationship: find the term_taxonomy_id by object_id (ex.430=post ID, term_taxonomy_id = 30) | |
- wp3p_term_taxonomy: change tl_activity_cat to tl_explore_cat where term_taxonomy_id (in this case, = 30) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment