Car Rental by SukcesStrony.pl
Car Rental by SukcesStrony.pl
if ( ! function_exists('sukcesstrony_car_rental') ) {
// Register Custom Post Type
function sukcesstrony_car_rental() {
$labels = array(
'name' => _x( 'Cars', 'Post Type General Name', 'sukcesstrony_car_rental' ),
'singular_name' => _x( 'Car', 'Post Type Singular Name', 'sukcesstrony_car_rental' ),
'menu_name' => __( 'Cars', 'sukcesstrony_car_rental' ),
'name_admin_bar' => __( 'Cars', 'sukcesstrony_car_rental' ),
'archives' => __( 'Archives', 'sukcesstrony_car_rental' ),
'parent_item_colon' => __( 'Parent Car:', 'sukcesstrony_car_rental' ),
'all_items' => __( 'All cars', 'sukcesstrony_car_rental' ),
'add_new_item' => __( 'Add new car', 'sukcesstrony_car_rental' ),
'add_new' => __( 'Add new', 'sukcesstrony_car_rental' ),
'new_item' => __( 'New car', 'sukcesstrony_car_rental' ),
'edit_item' => __( 'Edit car', 'sukcesstrony_car_rental' ),
'update_item' => __( 'Update car', 'sukcesstrony_car_rental' ),
'view_item' => __( 'View car', 'sukcesstrony_car_rental' ),
'search_items' => __( 'Search cars', 'sukcesstrony_car_rental' ),
'not_found' => __( 'Not found', 'sukcesstrony_car_rental' ),
'not_found_in_trash' => __( 'Not found in Trash', 'sukcesstrony_car_rental' ),
'featured_image' => __( 'Featured Image', 'sukcesstrony_car_rental' ),
'set_featured_image' => __( 'Set featured image', 'sukcesstrony_car_rental' ),
'remove_featured_image' => __( 'Remove featured image', 'sukcesstrony_car_rental' ),
'use_featured_image' => __( 'Use as featured image', 'sukcesstrony_car_rental' ),
'insert_into_item' => __( 'Insert into cars', 'sukcesstrony_car_rental' ),
'uploaded_to_this_item' => __( 'Uploaded to this car', 'sukcesstrony_car_rental' ),
'items_list' => __( 'Cars list', 'sukcesstrony_car_rental' ),
'items_list_navigation' => __( 'Cars list navigation', 'sukcesstrony_car_rental' ),
'filter_items_list' => __( 'Filter cars list', 'sukcesstrony_car_rental' ),
);
$rewrite = array(
'slug' => 'car',
'with_front' => true,
'pages' => true,
'feeds' => true,
);
$args = array(
'label' => __( 'Car', 'sukcesstrony_car_rental' ),
'description' => __( 'Car Rental', 'sukcesstrony_car_rental' ),
'labels' => $labels,
'supports' => array( 'title', 'editor', 'excerpt', 'thumbnail', 'revisions', 'custom-fields', 'page-attributes', ),
'taxonomies' => array( 'car-class', 'equipment' ),
'hierarchical' => false,
'public' => true,
'show_ui' => true,
'show_in_menu' => true,
'menu_position' => 5,
'show_in_admin_bar' => true,
'show_in_nav_menus' => true,
'can_export' => true,
'has_archive' => 'cars',
'exclude_from_search' => false,
'publicly_queryable' => true,
'rewrite' => $rewrite,
'capability_type' => 'page',
);
register_post_type( 'cars', $args );
}
add_action( 'init', 'sukcesstrony_car_rental', 0 );
}