SEO slug change

  • Author
    Posts
  • Aizen

    Hi iHor,

    I’ve changed the name and slug of the listing page in pages, but i notice the link still shows as url.com/LISTING/listing-name-slug

    I would like to change the emboldened part above from listing to whatever I would like or at least as the page indicates.

    Thanks,

    A

    Aizen

    Also – how to make uploaded images required? as I cannot see this option anywhere. Thanks

    ihor developer

    It’s possible to resolve both issues with a simple code snippet, I’ll post it on Monday (currently I’m on vacation and I don’t have access to my laptop).

    Aizen

    Thanks, I hope you enjoyed your vacation

    ihor developer

    1. Please add this code snippet to the child theme’s functions.php file and then refresh permalinks in Settings/Permalinks section:

    add_filter('hivepress/v1/post_types', function($args) {
        $args['listing']['rewrite']['slug']='custom-slug-here';
    
        return $args;
    });

    2. This code snippet should make the images field required:

    add_filter(
    	'hivepress/v1/models/listing',
    	function( $model ) {
    		$model['fields']['images']['required'] = true;
    
    		return $model;
    	}
    );
    juan

    Hi again ihor

    Please wich is the code snippet to change http://www.xxx.com/listing-category/ for SEO

    thanks a lot

    ihor developer

    Try this code snippet:

    add_filter('hivepress/v1/taxonomies', function($args) {
        $args['listing_category']['rewrite']['slug']='custom-slug-here';
    
        return $args;
    });

    Please refresh the permalinks after adding it.

    juan

    Thanks, for your Fast reply

Viewing 8 posts - 1 through 8 (of 8 total)

The topic ‘SEO slug change’ is closed to new replies.

Subscribe

Sign In

Don't have an account? Register

Forgot password?

Register

Already have an account? Sign In

Forgot password?

Reset Password

Please enter your username or email address, you will receive a link to create a new password via email.