WordPress.org

Ready to get started?Download WordPress

Forums

Clicky by Yoast
How to add clicky_custom.visitor code to the plugin default code? (3 posts)

  1. ratingshark
    Member
    Posted 1 year ago #

    Hi,
    I installed the plugin and it works great, but I am not able to find out how to change the code in order to activate the clicky_custom.visitor function, so I can see my logged in visitors usernames.

    http://wordpress.org/plugins/clicky/

  2. frankapicella
    Member
    Posted 11 months ago #

    Bump. I would really like to figure this out as well. I don't know how to integrate this properly:

    $user_info = get_userdata(1);

    $a = array();
    $a['type'] = "custom";
    $a['custom']['username'] = $user_info->user_login;
    $a['custom']['email'] = $user_info->user_email;

  3. frankapicella
    Member
    Posted 11 months ago #

    I'm not very good at PHP but I'm trying to implement this to track users if someone can help:

    /**
    * @param int $user_ID
    *
    */
    function clicky_track_user( $user_ID ) {

    $user_ID = get_current_user_id();
    $user_info = get_userdata(1);

    clicky_log(
    $a = array();
    $a['type'] = "custom";
    $a['custom']['username'] = $user_info->user_login;
    $a['custom']['email'] = $user_info->user_email;
    );
    }

    add_action( 'wp_login', 'clicky_track_user', 10, 2);

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic