MyBB Community Forums

Full Version: How to Display guest country and City in Who's Online page
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Who's Online [Complete List]
Generates a page of User ip, Time and page location.
I want to add user's country and ip address to it.

i have api that fetches country and city of given ipaddress.

http://www.talkthetech.com/inc/ip1.php?ip=66.90.197.159

But how to get ip address without any formating, fetch the location and put it next to ipaddress.
Try posting a request in the plugin section of the community forums.
Go to: ACP > Templates > Whos Online Templates > online_row_ip > and find;
{$lang->lookup}</a></span>
and Add the following code just After that;
<br/>
<span class="smalltext">Country: http://www.talkthetech.com/inc/ip1.php?ip={$user['ip']}</span>
Does it fetch the text from the page or just provide link to see the country and city?
It just provide a link. As you've said that you've API that fetches country and city of given ipaddress.
Just wanted say that this dramatically reduces performance on your Who's Online page. Loading time takes forever.