xprofile_delete_activity( array|string $args = '' )

Deletes activity for a user within the profile component so that it will be removed from the users activity stream and sitewide stream (if installed).

Parameters Parameters


(array|string) (Optional) Containing all variables used after bp_parse_args() call.

Default value: ''

Top ↑

Return Return


Source Source

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

function xprofile_delete_activity( $args = '' ) {

	// Bail if activity component is not active.
	if ( ! bp_is_active( 'activity' ) ) {
		return false;

	// Parse the arguments.
	$r = bp_parse_args( $args, array(
		'component' => buddypress()->profile->id
	), 'xprofile_delete_activity' );

	// Delete the activity item.
	bp_activity_delete_by_item_id( $r );

Top ↑

Changelog Changelog

Version Description
1.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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