bp_current_action()

Return the name of the current action.

Description

Return

(string) Action name.

Source

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

function bp_current_action() {
	$bp             = buddypress();
	$current_action = !empty( $bp->current_action )
		? $bp->current_action
		: '';

	/**
	 * Filters the name of the current action.
	 *
	 * @since BuddyPress 1.0.0
	 *
	 * @param string $current_action Current action.
	 */
	return apply_filters( 'bp_current_action', $current_action );
}

Changelog

Changelog
Version Description
BuddyPress 1.0.0 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.