PHP code example of stuttter / wp-user-activity

1. Go to this page and download the library: Download stuttter/wp-user-activity library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

stuttter / wp-user-activity example snippets


Admin created the post "Hello World" 33 seconds ago.

add_filter( 'wp_get_default_user_activity_types', function( $types = array() ) {
	$types[] = 'Your_New_Type'; // extends `WP_User_Activity_Type`
	return $types;
} );