• I recently update my Astra theme and now I cannot select sidebar or layout options in my custom post type. I can select “No Sidebar” and then update but it does not set. I created a custom post type using this code.

    // Our custom post type function
    function create_location_posttype() {
     
        register_post_type( 'location',
        // CPT Options
            array(
                'labels' => array(
                    'name' => __( 'Location' ),
                    'singular_name' => __( 'Location' )
                ),
                'public' => true,
                'has_archive' => true,
                'rewrite' => array('slug' => 'location'),
                'show_in_rest' => true,
     
            )
        );
    	
    }
    // Hooking up our function to theme setup
    add_action( 'init', 'create_location_posttype' );

    I was trying to create a single-location.php page to have no side bar, but I remove the sidebar lines and the sidebar section remains but except it is empty. Any help would be appreciated.

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)

The topic ‘Astra Theme and Site Layout Customizer’ is closed to new replies.