Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Change "portfolio" slug of "Portfolio" custom post type to "about"
- function change_portfolio_post_types_slug( $args, $post_type ) {
- /*item post type slug*/
- if ( 'portfolio' === $post_type ) {
- $args['rewrite']['slug'] = 'about';
- }
- return $args;
- }
- add_filter( 'register_post_type_args', 'change_portfolio_post_types_slug', 10, 2 );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement