bbp_add_template_stack_locations( $stacks = array() )

Add template locations to template files being searched for

Description

Parameters

$templates

(Required)

Return

(array())

Source

File: bp-forums/core/template-functions.php

function bbp_add_template_stack_locations( $stacks = array() ) {
	$retval = array();

	// Get alternate locations
	$locations = bbp_get_template_locations();

	// Loop through locations and stacks and combine
	foreach ( (array) $stacks as $stack )
		foreach ( (array) $locations as $custom_location )
			$retval[] = untrailingslashit( trailingslashit( $stack ) . $custom_location );

	return apply_filters( 'bbp_add_template_stack_locations', array_unique( $retval ), $stacks );
}

Changelog

Changelog
Version Description
bbPress (r3738) Introduced.

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.