I’ve made some custom templates in my theme, and I have them in the config.php file as follows to remove the primary sidebar from them. However, at the bottom of each page the primary sidebar content is showing up after the end of /main. Any ideas? The only way I’ve been able to remove it has been to have no content in the primary sidebar, and it is happening on templates that have a custom sidebar i made pulled and the regular templates as well (I’m a bit of a beginner on roots, so my apologies if it’s just me being dumb):
function roots_display_sidebar() {
$sidebar_config = new Roots_Sidebar(
/**
* Conditional tag checks (http://codex.wordpress.org/Conditional_Tags)
* Any of these conditional tags that return true won't show the sidebar
*
* To use a function that accepts arguments, use the following format:
*
* array('function_name', array('arg1', 'arg2'))
*
* The second element must be an array even if there's only 1 argument.
*/
array(
'is_404',
'is_front_page'
),
/**
* Page template checks (via is_page_template())
* Any of these page templates that return true won't show the sidebar
*/
array(
'template-custom.php',
'template-home.php',
'template-postpage.php'
)
);
return apply_filters('roots_display_sidebar', $sidebar_config->display);
}