bp_blogs_setup_comment_loop_globals_on_ajax()

Set up some globals used in the activity comment loop when AJAX is used.


Description Description

See also See also


Top ↑

Source Source

File: bp-blogs/bp-blogs-activity.php

function bp_blogs_setup_comment_loop_globals_on_ajax() {
	// Not AJAX? stop now!
	if ( ! defined( 'DOING_AJAX' ) ) {
		return;
	}
	if ( false === (bool) constant( 'DOING_AJAX' ) ) {
		return;
	}

	// Get the parent activity item.
	$comment         = bp_activity_current_comment();
	$parent_activity = new BP_Activity_Activity( $comment->item_id );

	// Setup the globals.
	bp_blogs_setup_activity_loop_globals( $parent_activity );
}


Top ↑

Changelog Changelog

Changelog
Version Description
2.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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