你可以从this 文章
您将在中找到更多信息rewrite 文章的属性描述。
例如:。
add_action( \'init\', \'create_my_post_types\' );
function create_my_post_types()
{
register_post_type( \'super_duper\',
array(
\'labels\' => array
(
\'name\' => __( \'Super Dupers\' ),
\'singular_name\' => __( \'Super Duper\' ),
\'add_new\' => __( \'Add New\' ),
\'add_new_item\' => __( \'Add New Super Duper\' ),
\'edit\' => __( \'Edit\' ),
\'edit_item\' => __( \'Edit Super Duper\' ),
\'new_item\' => __( \'New Super Duper\' ),
\'view\' => __( \'View Super Duper\' ),
\'view_item\' => __( \'View Super Duper\' ),
\'search_items\' => __( \'Search Super Dupers\' ),
\'not_found\' => __( \'No super dupers found\' ),
\'not_found_in_trash\' => __( \'No super dupers found in Trash\' ),
\'parent\' => __( \'Parent Super Duper\' ),
),
\'public\' => true,
\'show_ui\' => true,
\'publicly_queryable\' => true,
\'exclude_from_search\' => false,
\'rewrite\' => array( slug => \'New_label\',\'with_front\' => true ),
)
);
}
提供在重写参数的slug值中使用的slug,以获得所需的permalink。