How can I locate the single buddypress forum post template? [closed]

Even if I’m also not quite sure if this question is related to bbPress or BuddyPress, locating (plugin-) template files might always be the same: An easy approach might be to call the body_class() in a file which is definitely active (like header.php). The output will look something like this: class=”forum-archive bbpress archive post-type-archive post-type-archive-forum … Read more

Custom SINGLE page with custom metaboxes and custom template

Simlified function, maybe will help someone: jQuery(document).ready(function($) { $(“#page_template”).change(function() { if($(‘#page_template’).val() != ‘page-contacts.php’) { // show the meta box $(‘#postdivrich’).show(); } else { // hide your meta box $(‘#postdivrich’).hide(); } }).change(); }); Of course it lacks controls what fields will be submitted, because jQuery just hides them. As I am coding it for one-admin user … Read more

What is the point of using the front-page.php template? [closed]

You would use the front-page.php template because it allows to have custom content and layout for your website’s static front page. You can edit content on your static front page from inside the WordPress admin if the front-page.php template contains the the_content() template tag or similar. It really depends on what your content and presentation … Read more

Custom post type is_singular condtional not working when managing sidebar display

I refactored the if conditional using suggestions from Jacob Peattie and the following fixed my issues. if ( ! is_page_template( array( ‘template-investment.php’, ‘template-tourism.php’ ) ) && ! is_tax( ‘listings’ ) && ! is_singular( ‘listing’ ) ) { The result correctly removed the sidebar.php from loading its code on specific templates, taxonomy, and single post type.