Quantcast
Channel: WordPress › Support » Forum: Hacks - Recent Topics
Viewing all articles
Browse latest Browse all 8245

Jimbola on "Change page template based on layout in Site Origins Page Builder"

$
0
0

I am using Site Origins Page Builder to create a pre-built layout using the code;

function mytheme_prebuilt_layouts($layouts){
    $layouts['home-page'] = array(
        // We'll add a title field
        'name' => __('Default Home', 'vantage'),    // Required
        'description' => __('Default Home Description', 'vantage'),    // Optional
        'widgets' => array( ... ),
        'grids' => array( ... ),
        'grid_cells' => array( ... )
    );
    return $layouts;

}
add_filter('siteorigin_panels_prebuilt_layouts','mytheme_prebuilt_layouts');

Is there a way to change the page template that is used based on the name of the layout that has been selected?


Viewing all articles
Browse latest Browse all 8245

Trending Articles