users - delete_user hook failed

I would like to delete a specific post when the user is deleted in adminusers.php.I did this code :add_action('d

I would like to delete a specific post when the user is deleted in admin/users.php.

I did this code :

add_action('delete_user', array(__CLASS__, "delete_user_profile"), 10 ); //I´m sure the code passed by here.

public static function delete_user_profile( $user_id ){
    var_dump( $user_id ); //Never called
    wp_die( "delete_user_profile");

}

What could be the problem ? Is there a different way or hook to do this ?

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1742304190a4418608.html

相关推荐

  • users - delete_user hook failed

    I would like to delete a specific post when the user is deleted in adminusers.php.I did this code :add_action('d

    15小时前
    10

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信