Skip to:
Content
Pages
Categories
Search
Top
Bottom

Reply To: Curious if this is correct php for showing X to Z people.

@macpresss

Participant

Thanks..

We’ll keep learning each day.

I just found out that you can easily overwrite exciting functions or actions with just two little steps.


function shmoo_messages_screen_notification_settings() {
	if ( bp_action_variables() ) {
		bp_do_404();
		return;
	}
.... wall of code ....

}
remove_action( 'bp_notification_settings', 'messages_screen_notification_settings', 2 );
add_action( 'bp_notification_settings', 'shmoo_messages_screen_notification_settings', 10 );

I just copied the original code to my functions.php renamed the function name by simply adding shmoo in front of it and last add the remove_action() tag just above the add_action with the original function that you wanna hide.

So cool. Now I can change more dynamic content into my own content.

Skip to toolbar