Create WP Posts (or any Post Types)
Version 1.0.0 added 1 year ago by sc0ttkclark
HOW TO INSTALL: To install this package, copy the following code and paste it into your Pods >> Package Manager under the Import tab and follow instructions there.
1.0.0 Notes
Fresh release
About this Package
This package is loosely based on the code from k0nG's package "Create WordPress Post / Page" but offering many new options. Additional help from hsatterwhite on testing and feature suggestions.
If you used to use the Create WordPress Post / Page package then just install this package and change your corresponding Pods to use the 'save_post' helper in the Pre-save Helper option.
Features:
- Runs on Pre-save (to save the ID of the post along with the other pod data)
- Saves ID of created Post (or other post_type) in the current Pod item
- Define the default post_type (default 'post')
- Define the default column to be used for post_title (default 'name')
- Define the default column to be used for storing the post ID (can be TXT or PICK coltype) (default 'wp_post_id')
- Define the default date column to be used for post_date (default false - use now)
- Define the default categories to be used for post_category (can be comma-separated 1,4,3 or array) (default false - no categories)
- Define the default column to be used for post_category (can be TXT, NUM or PICK coltype) (default false - no categories)
- Define the default column to be used for post_content (default false - no content)
- Define the default post_parent (default false - no parent)
- Define the default column to be used for post_parent (default false - no parent)
- Define the default post_status (default 'publish')
- Define the default comment_status (defaults to WP option 'default_comment_status')
- Define the default ping_status (defaults to WP option 'default_ping_status')
If you used to use the Create WordPress Post / Page package then just install this package and change your corresponding Pods to use the 'save_post' helper in the Pre-save Helper option.
Features:
- Runs on Pre-save (to save the ID of the post along with the other pod data)
- Saves ID of created Post (or other post_type) in the current Pod item
- Define the default post_type (default 'post')
- Define the default column to be used for post_title (default 'name')
- Define the default column to be used for storing the post ID (can be TXT or PICK coltype) (default 'wp_post_id')
- Define the default date column to be used for post_date (default false - use now)
- Define the default categories to be used for post_category (can be comma-separated 1,4,3 or array) (default false - no categories)
- Define the default column to be used for post_category (can be TXT, NUM or PICK coltype) (default false - no categories)
- Define the default column to be used for post_content (default false - no content)
- Define the default post_parent (default false - no parent)
- Define the default column to be used for post_parent (default false - no parent)
- Define the default post_status (default 'publish')
- Define the default comment_status (defaults to WP option 'default_comment_status')
- Define the default ping_status (defaults to WP option 'default_ping_status')
