• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Is possible to change Portfolio slug?

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › General Discussion › Is possible to change Portfolio slug?

This topic is: resolved

Tagged: portfolio

  • This topic has 4 replies, 2 voices, and was last updated 9 years, 11 months ago by rcorai.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • February 16, 2016 at 10:19 am #179145
    rcorai
    Member

    I would like to change Portfolio slug for other term but I couldn't find how to do it.

    This tutorial works only with Category posts: http://my.studiopress.com/tutorials/category-blog-page/

    But I would like to find something similar.

    Any help?

    http://ricardocorai.com
    February 16, 2016 at 5:18 pm #179196
    Jeff
    Member

    Did you build your site off of a specific theme? Or did you create a portfolio custom post type?

    February 16, 2016 at 7:04 pm #179199
    rcorai
    Member

    Right now I'm using Minimalist PRO. It has portfolio post type included and works fine. But I would like to rename the slug from portfolio to gallery or something like that.

    mydomain.com/porfolio/ to mydomain.com/gallery/

    Thanks

    February 16, 2016 at 7:16 pm #179201
    Jeff
    Member

    Do you mean minimum pro? To change the slug, you'll need to edit your functions.php file. Look for the block of code that looks like this:

    
    //* Create portfolio custom post type
    add_action( 'init', 'minimum_portfolio_post_type' );
    function minimum_portfolio_post_type() {
    
    	register_post_type( 'portfolio',
    		array(
    			'labels' => array(
    				'name'          => __( 'Portfolio', 'minimum' ),
    				'singular_name' => __( 'Portfolio', 'minimum' ),
    			),
    			'exclude_from_search' => true,
    			'has_archive'         => true,
    			'hierarchical'        => true,
    			'menu_icon'           => 'dashicons-admin-page',
    			'public'              => true,
    			'rewrite'             => array( 'slug' => 'portfolio', 'with_front' => false ),
    			'supports'            => array( 'title', 'editor', 'author', 'thumbnail', 'excerpt', 'trackbacks', 'custom-fields', 'revisions', 'page-attributes', 'genesis-seo' ),
    		)
    	);
    	
    }

    On the line that says "'rewrite' => array( 'slug' => 'portfolio', 'with_front' => false )," change the word portfolio to gallery. Make sure to keep the single quotes. You can also change the name and the singular_name so it shows up as gallery on the WordPress admin page. I hope that makes sense.

    March 1, 2016 at 12:14 pm #180351
    rcorai
    Member

    Thank you Jeff!

  • Author
    Posts
Viewing 5 posts - 1 through 5 (of 5 total)
  • The forum ‘General Discussion’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2026 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble