Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Community Forums
 Show-Off Your Forums
 New improvements to myforum.dk
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

i011877
Junior Member

Denmark
169 Posts

Posted - 03 February 2009 :  05:32:21  Show Profile  Visit i011877's Homepage  Reply with Quote
Hey there

Yet again many changes to www.myforum.dk
To many to mention, so go have a look for yourself

User:testuser
Pass:testuser

active_users.asp
I have searched the forum for anything similar to the 'MOD' i have made, but without luck.
It shows the country of origin for visitors, with a small flag.
Mouseover the flag to see the name of the country and ip.

Well, just wanted to show you, as I have not seen anything similar elsewhere.

Preview


<


MarcelG
Retired Support Moderator

Netherlands
2625 Posts

Posted - 03 February 2009 :  08:51:30  Show Profile  Visit MarcelG's Homepage  Reply with Quote
Nice mod! How do you determine the country? Is it based on a DNS query?<

portfolio - linkshrinker - oxle - twitter
Go to Top of Page

i011877
Junior Member

Denmark
169 Posts

Posted - 03 February 2009 :  09:55:51  Show Profile  Visit i011877's Homepage  Reply with Quote
Well, it's actually determined by IP, which is fairly easy to get from visitors. All ip's belong to a specific region or country.
IP is then converted to Long-IP with a formula, then it looks in DB for country or region with that number.
Each number then corresponds to a name e.g. DENMARK.
Then it picks the flag for that country and displays it.

Hmm kinda hard to explain

I only tried this with MSSQL, but it will work on mysql as well.


<


Go to Top of Page

HuwR
Forum Admin

United Kingdom
20584 Posts

Posted - 03 February 2009 :  10:19:57  Show Profile  Visit HuwR's Homepage  Reply with Quote
FYI IP ranges although generally country specific, may not necessarily indicate the actual country of the visitor as some ISP's assign IP's which may not relate to the users physical location (AOL is a classic example)<
Go to Top of Page

bobby131313
Senior Member

USA
1163 Posts

Posted - 03 February 2009 :  11:18:18  Show Profile  Visit bobby131313's Homepage  Reply with Quote
I have 2 members in France whose IP traces to Germany because thier ISP is Deutsche Telekom AG which seems to have subsidiaries in several countries.<

Switch the order of your title tags
Go to Top of Page

i011877
Junior Member

Denmark
169 Posts

Posted - 03 February 2009 :  14:24:35  Show Profile  Visit i011877's Homepage  Reply with Quote
Yea well, it's not a bulletproof addition.

I guess if several users from different regions logged in with my 'testuser', it would not show the correct country.

For a short period, I have enabled active users for non-members.
Check to see if your flag is right

I'm happy if I can get most of them right, so prove me wrong...

-Bobby, have your 2 members visit, to check if their flag is the right one.<



Edited by - i011877 on 03 February 2009 14:43:18
Go to Top of Page

HuwR
Forum Admin

United Kingdom
20584 Posts

Posted - 03 February 2009 :  15:22:01  Show Profile  Visit HuwR's Homepage  Reply with Quote
well, I'm not on aol and know that my IP is a uk ip, so there is no point , I was merely pointing out that you can not assume that they are correct, you don't have any choice in whether your code is right or not, that is entirely up to the ISP when it doles out from its ip pool.<
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.11 seconds. Powered By: Snitz Forums 2000 Version 3.4.07