• Resolved mathiasvissers

    (@mathiasvissers)


    Is it possible to change the first part of the slug of the FAQ-module, from /sp_faq/ to something else?

    Thank you!

Viewing 1 replies (of 1 total)
  • Hello @mathiasvissers,

    Yes, It is possible with wordpress register_post_type_args filter hook.
    Please put below code in your theme’s function.php file

    add_filter( ‘register_post_type_args’, ‘themename_register_post_type_args’, 10, 2 );
    function themename_register_post_type_args( $args, $post_type ) {

    if ( ‘sp_faq’ === $post_type ) {
    $args[‘rewrite’][‘slug’] = ‘my_faq_slug’; //here your custom slug
    }

    return $args;
    }

    Hope this code will be helpful.

    Thanks & Regards
    WP Online Support

Viewing 1 replies (of 1 total)
  • The topic ‘Change slug sp_faq’ is closed to new replies.