Question on customized sidebar
-
Hi, you kindly answered my question and had it resolved but I have a follow up pls!
Regarding customizing the sidebar per catgory, I couldn’t get it to work.
Is it because I am using your other plugin called “Ocean Custom Sidebar”?
So, just to confirm again, I created a “Custom Sidebar” called: ‘ocs-tester-sidebarx’
The category I would like to display that on is titled ‘Alaska’ – slug would be ‘alaska’
I made the changes as per below but no joy…
++++ START
function my_custom_sidebar_display( $sidebar ) {
// Return a different sidebar for custom post type ‘gallery’
if ( is_singular( ‘alaska’ ) ) {
return ‘ocs-tester-sidebarx’;
}
// Return theme defined sidebar area
else {
return $sidebar;
}
}
add_filter( ‘ocean_get_sidebar’, ‘my_custom_sidebar_display’ );+++++ End
Am I doing something wrong here? I tried different variations…
Is it because my custom post type is created by WordPress PODS Framework?
I was hoping the custom sidebar would load on the official WordPress category…
Thanks for all advice/ help!
- The topic ‘Question on customized sidebar’ is closed to new replies.