Created
November 14, 2017 21:23
-
-
Save Sstobo/fe410434fb3de1b233800367695cab8e to your computer and use it in GitHub Desktop.
[WP Plugin dev] #wp #plugins
This file contains hidden or 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
function inhabitent_cpt_product() { | |
$args = array(); | |
register_post_type( 'product', $args ); | |
} | |
add_action( 'init', 'inhabitent_cpt_product' ); | |
## FLUSH PERMALINK CACHE When adding new content type or templates OR HAVING PROBLEMS ## | |
go to settings on dash | |
permalinks ---> save | |
use Generate Wordpress Post Type | |
Generate post type / taxonomy | |
Copy into post-types.php and taxonomies.php in plugin boiler plate | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment