OwlCyberSecurity - MANAGER
Edit File: class-ova-templates-loaders.php
<?php if ( !defined( 'ABSPATH' ) ) { exit; } class OVASERMON_templates_loader { /** * The Constructor */ public function __construct() { add_filter( 'template_include', array( $this, 'template_loader' ) ); } public function template_loader( $template ) { $post_type = isset($_REQUEST['post_type'] ) ? esc_html( $_REQUEST['post_type'] ) : get_post_type(); if( is_tax( 'cat_sermon' ) || (get_query_var( 'cat_sermon' ) != '') || is_tax( 'sermon_by' ) || (get_query_var( 'sermon_by' ) != '') ) { ovasermon_get_template( 'archive-sermon.php' ); return false; } // Is Sermon Post Type if( $post_type == 'sermon' ){ if ( is_post_type_archive( 'sermon' ) ) { ovasermon_get_template( 'archive-sermon.php' ); return false; } else if ( is_single() ) { ovasermon_get_template( 'single-sermon.php' ); return false; } } if ( $post_type !== 'sermon' ){ return $template; } } } new OVASERMON_templates_loader();