Skip to content
This repository has been archived by the owner on Jan 29, 2024. It is now read-only.

URL slug not translatable #20

Open
scarinessreported opened this issue Jan 9, 2015 · 1 comment
Open

URL slug not translatable #20

scarinessreported opened this issue Jan 9, 2015 · 1 comment

Comments

@scarinessreported
Copy link

The custom post type slug for listings is not translatable.

The fix for this is below.
class-listings.php line number 91:
'rewrite' => array( 'slug' => _x( 'listings', 'agentpress-listings' ) ),

@dreamwhisper
Copy link

@scarinessreported There is a filter if you do need to change it for now. (requires permalink resave)

add_filter( 'agentpress_listings_post_type_args', 'child_agentpress_listings_post_type_args' );
function child_agentpress_listings_post_type_args( $args ){
    $args['rewrite']['slug'] = 'slugname';
    return $args;
}

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants