Created
March 29, 2015 17:48
-
-
Save BFTrick/421d3dce1852be6aae98 to your computer and use it in GitHub Desktop.
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
| <?php | |
| add_filter( 'registered_post_type', 'my_portfolio_cpt', 20, 2 ); | |
| function my_portfolio_cpt( $post_type, $args ) { | |
| if ( 'portfolio-item' == $post_type ) { | |
| global $wp_post_types; | |
| $args->rewrite->slug = __( 'resources', 'my_theme_textdomain' ); | |
| $wp_post_types[ $post_type ] = $args; | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment