bbp_maybe_get_root_slug()

Maybe return the root slug, based on whether or not it’s included in the url


Description Description


Parameters Parameters

$default

(Optional) Default value 'forums'


Top ↑

Return Return

(string)


Top ↑

Source Source

File: includes/core/options.php

function bbp_maybe_get_root_slug() {
	$slug   = bbp_get_root_slug();
	$retval = ( ! empty( $slug ) && bbp_include_root_slug() )
		? trailingslashit( $slug )
		: '';

	// Filter & return
	return apply_filters( 'bbp_maybe_get_root_slug', $retval );
}

Top ↑

Changelog Changelog

Changelog
Version Description
2.1.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.