Hello.
I’m trying to change the layout in a particular page using this code in functions.php
function dom_barra_en_especialidades( $layout ){
if ( is_page('the-slug') ){
return 'left-sidebar';
} else {
return $layout;
}
}
add_filter( 'generate_sidebar_layout','dom_barra_en_especialidades' );
The default setting is to Content with no sidebars, but I want the left sidebar in that page. I’m still getting the default layout.
Where I’m getting wrong?
Hello
Ok, It seems there’s an issue using Sections with this.
If I set Sidebar/Content in the metabox in the page and I don’t use Sections, it actually shows the left sidebar. But if I use Sections, the sidebar is not displayed.
Is there a way to solve this?