PHP Class SimpleUserLogger

Inheritance: extends SimpleLogger
Afficher le fichier Open project: bonny/wordpress-simple-history

Méthodes publiques

Свойство Type Description
$slug

Méthodes publiques

Méthode Description
add_diff ( $post_data_diff, $key, $old_value, $new_value ) Add diff to array if old and new values are different
getInfo ( ) : array Get array with information about this logger
getLogRowDetailsOutput ( $row ) Return more info about an logged event Supports so far:
getLogRowPlainTextOutput ( $row ) Modify plain text row output - adds link to user profil - change to "your profile" if you're looking at your own edit
loaded ( ) Add actions and filters when logger is loaded by Simple History
on_authenticate ( $user, $username, $password ) Attempt to login to user that does not exist
on_delete_user ( integer $user_id, integer | null $reassign ) Fires before a user is deleted from the database.
on_destroy_user_session ( ) Called when user dessions are destroyed from admin Can be called for current logged in user = destroy all other sessions or for another user = destroy alla sessions for that user Fires from AJAX call
on_insert_user_meta ( $meta, $user, $update ) * Called before the user is updated
on_profile_update ( integer $user_id, object $old_user_data ) User is edited
on_retrieve_password_message ( $message, $key, $user_login, $user_data ) user requests a reset password link
on_user_register ( $user_id ) User is created
on_validate_password_reset ( object $errors, WP_User | WP_Error $user ) Fired before the password reset procedure is validated.
on_wp_authenticate_user ( object $user, $password ) Log failed login attempt to username that exists
on_wp_login ( string $user_login = null, object $user = null ) User logs in
on_wp_logout ( ) User logs out http://codex.wordpress.org/Plugin_API/Action_Reference/wp_logout

Method Details

add_diff() public méthode

Since 2.0.29
public add_diff ( $post_data_diff, $key, $old_value, $new_value )

getInfo() public méthode

Get array with information about this logger
public getInfo ( ) : array
Résultat array

getLogRowDetailsOutput() public méthode

Return more info about an logged event Supports so far:
public getLogRowDetailsOutput ( $row )

getLogRowPlainTextOutput() public méthode

Modify plain text row output - adds link to user profil - change to "your profile" if you're looking at your own edit
public getLogRowPlainTextOutput ( $row )

loaded() public méthode

Add actions and filters when logger is loaded by Simple History
public loaded ( )

on_authenticate() public méthode

Attempt to login to user that does not exist
public on_authenticate ( $user, $username, $password )
$user (null or WP_User or WP_Error) (required) null indicates no process has authenticated the user yet. A WP_Error object indicates another process has failed the authentication. A WP_User object indicates another process has authenticated the user.
$username The user's username. since 4.5.0 `$username` now accepts an email address.
$password The user's password (encrypted)

on_delete_user() public méthode

Fires before a user is deleted from the database.
public on_delete_user ( integer $user_id, integer | null $reassign )
$user_id integer ID of the deleted user.
$reassign integer | null ID of the user to reassign posts and links to. Default null, for no reassignment.

on_destroy_user_session() public méthode

Called when user dessions are destroyed from admin Can be called for current logged in user = destroy all other sessions or for another user = destroy alla sessions for that user Fires from AJAX call
Since: 2.0.6

on_insert_user_meta() public méthode

Filter a user's meta values and keys before the user is created or updated. Does not include contact methods. These are added using wp_get_user_contact_methods( $user ).
public on_insert_user_meta ( $meta, $user, $update )
$meta { Default meta values and keys for the user. @type string $nickname The user's nickname. Default is the user's username. @type string $first_name The user's first name. @type string $last_name The user's last name. @type string $description The user's description. @type bool $rich_editing Whether to enable the rich-editor for the user. False if not empty. @type bool $comment_shortcuts Whether to enable keyboard shortcuts for the user. Default false. @type string $admin_color The color scheme for a user's admin screen. Default 'fresh'. @type int|bool $use_ssl Whether to force SSL on the user's admin area. 0|false if SSL is not forced. @type bool $show_admin_bar_front Whether to show the admin bar on the front end for the user. Default true. }
$user User object.
$update Whether the user is being updated rather than created.

on_profile_update() public méthode

Called immediately after an existing user is updated.
public on_profile_update ( integer $user_id, object $old_user_data )
$user_id integer User ID.
$old_user_data object Object containing user's data prior to update.

on_retrieve_password_message() public méthode

user requests a reset password link
public on_retrieve_password_message ( $message, $key, $user_login, $user_data )

on_user_register() public méthode

"This action hook allows you to access data for a new user immediately after they are added to the database. The user id is passed to hook as an argument."
public on_user_register ( $user_id )

on_validate_password_reset() public méthode

Fired before the password reset procedure is validated.
public on_validate_password_reset ( object $errors, WP_User | WP_Error $user )
$errors object WP Error object.
$user WP_User | WP_Error WP_User object if the login and reset key match. WP_Error object otherwise.

on_wp_authenticate_user() public méthode

Log failed login attempt to username that exists
public on_wp_authenticate_user ( object $user, $password )
$user object user object that was tried to gain access to

on_wp_login() public méthode

User logs in
public on_wp_login ( string $user_login = null, object $user = null )
$user_login string
$user object

on_wp_logout() public méthode

User logs out http://codex.wordpress.org/Plugin_API/Action_Reference/wp_logout
public on_wp_logout ( )

Property Details

$slug public_oe property

public $slug