• Resolved pabstsmeared

    (@pabstsmeared)


    Hi-

    I believe I have a similar issue to a previous poster about how the IP tracking is reporting a local server IP address. I tried following the previous instructions but I did not see php file in the following path:
    wordpress\wp-content\plugins\user-login-history\admin\class-user-login-history-user-tracker.php

    Can you please advise of any changes that may have happened since the last post?

    These are the options I have:

    View post on imgur.com

    Thanks!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Faiyaz Alam

    (@faiyazalam)

    Can you please share the link of the previous poster?

    The user tracker file is located at :
    /wordpress/wp-content/plugins/user-login-history/includes/class-faulh-user-tracker.php

    Also, could you please share a step by step description of the bug?

    Thanks

    Thread Starter pabstsmeared

    (@pabstsmeared)

    Thanks for the quick reply.

    Previous post I thought might be a similar situation to what I am experiencing: https://www.ads-software.com/support/topic/ip-issue/

    Here is a sample of what is happening: https://imgur.com/a/zfpUvY3

    I tried making changes here but it didn’t work. Should I be doing something different? Thanks again.

    View post on imgur.com

    Plugin Author Faiyaz Alam

    (@faiyazalam)

    Replace the function in the file:
    user-login-history/includes/class-faulh-geo-helper.php

    public function get_ip() {
    	           
    	            $ip_address = $_SERVER['REMOTE_ADDR'];
    	
    	            if (!empty($_SERVER['HTTP_CLIENT_IP'])) {
    	                $ip_address = $_SERVER['HTTP_CLIENT_IP'];
    	            } elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) {
    	                $ip_address = $_SERVER['HTTP_X_FORWARDED_FOR'];
    	            }elseif (!empty($_SERVER['HTTP_X_REAL_IP'])) {
    	                $ip_address = $_SERVER['HTTP_X_REAL_IP'];
    	            }
                return $ip_address;
    	        }

    Please let me know if it works.

    • This reply was modified 6 years, 1 month ago by Faiyaz Alam.
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘IP Reporting’ is closed to new replies.