Locaties
locatiebeheer tlzj
// Register Custom Post Type function locations_post_type() { $labels = array( 'name' => _x( 'Locations', 'Post Type General Name', 'jdpro_locations' ), 'singular_name' => _x( 'Location', 'Post Type Singular Name', 'jdpro_locations' ), 'menu_name' => __( 'Locatie', 'jdpro_locations' ), 'name_admin_bar' => __( 'Locaties', 'jdpro_locations' ), 'parent_item_colon' => __( 'Hoofd item:', 'jdpro_locations' ), 'all_items' => __( 'Alle locaties', 'jdpro_locations' ), 'add_new_item' => __( 'Nieuwe locatie toevoegen', 'jdpro_locations' ), 'add_new' => __( 'Voeg toe', 'jdpro_locations' ), 'new_item' => __( 'Nieuwe locatie', 'jdpro_locations' ), 'edit_item' => __( 'Bewerk locatie', 'jdpro_locations' ), 'update_item' => __( 'Update locatie', 'jdpro_locations' ), 'view_item' => __( 'Bekijk locatie', 'jdpro_locations' ), 'search_items' => __( 'Zoek locaties', 'jdpro_locations' ), 'not_found' => __( 'Geen locaties gevonden', 'jdpro_locations' ), 'not_found_in_trash' => __( 'Geen locaties gevonden in prullenbak', 'jdpro_locations' ), ); $rewrite = array( 'slug' => 'locatie', 'with_front' => true, 'pages' => true, 'feeds' => true, ); $args = array( 'label' => __( 'location', 'jdpro_locations' ), 'description' => __( 'Locatiebeheer', 'jdpro_locations' ), 'labels' => $labels, 'supports' => array( 'title', 'editor', 'excerpt', 'custom-fields', 'page-attributes', ), 'taxonomies' => array( 'category', 'post_tag' ), 'hierarchical' => false, 'public' => true, 'show_ui' => true, 'show_in_menu' => true, 'menu_position' => 5, 'menu_icon' => 'dashicons-location-alt', 'show_in_admin_bar' => true, 'show_in_nav_menus' => true, 'can_export' => true, 'has_archive' => true, 'exclude_from_search' => false, 'publicly_queryable' => true, 'rewrite' => $rewrite, 'capability_type' => 'page', ); register_post_type( 'location', $args ); } // Hook into the 'init' action add_action( 'init', 'locations_post_type', 0 );