[RC13] IP Country Flag 2.9.6b full (2008-03-20)

A place for MOD Authors to post and receive feedback on MODs still in development. No MODs within this forum should be used within a live environment! No new topics are allowed in this forum.
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: MOD Development Forum rules

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.
Locked
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

[RC13] IP Country Flag 2.9.6b full (2008-03-20)

Post by 3Di »

MOD Title: IP Country Flag
MOD Description: It's a kind of IP Country Flags Invasion, read the Author notes for further infos ;)
MOD Version: 2.9.6b

MOD Download: http://mods.io3di.com/ipcf296b.zip (very stable version)
Last Stable version: N/A

Demo Board: http://ipcf.io3di.com/
Demo Username: N/A
Demo Password: N/A

old topic: http://www.phpbb.com/phpBB/viewtopic.php?t=295639
:!: codechanges 2.9.6a to 2.9.6b: http://mods.io3di.com/ipcf_296b_update.txt
Have fun and please read the installation file accurately.
Last edited by 3Di on Thu Mar 20, 2008 9:16 pm, edited 67 times in total.
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Post by 3Di »

##
## 2008-03-20 - Version 2.9.6b
## - general maintenance
## - tested with phpBB 2.0.23 and easymod 0.3.0 (fresh install), php5 and mysql5
## - finalized, for good, the built-in antispam protection
## - language file amended
## - credits updated in two files (I need them to be there, in place, in order to give assistance for free at your forum)
##
## 2007-06-16 - Version 2.9.6a
## - removed a redundant EM action for topic_review.php, no harm.. though. ;)
## - added basic antispam protection in the drop-down menu under registration
## - back-ported from Olympus CVS some code for the IP Database Populator (mysql5/php5 help)
## - removed wrong guest flags from viewtopic
## - code cleaning for an IF statement, there in viewtopic.
## - removed local time for Guests, in viewtopic.
## - BUG fixed - secondary user flag of choice it was wrong after the user profile edit.
## - external language file amended to reflect all changes.
## - tested with EM 0.3.0 on a fresh phpBb 2.0.22
##
## 2007-03-25 - Version 2.9.4
## - BUG fixed - past 24hrs guests flags are blank in some cases (thanks Dicky).
## - BUG fixed - secondary user flag of choice is blank if not seleceted while registering.
## - typo in language file fixed (double 'last' on index)
## - added compatibility for mySql >5 into the DB Populator (thx Mitron)
## - tested with EM 0.3.0 on a fresh phpBB 2.0.22 install in localhost (both mySql4 & 5).
##
## 2007-01-16 - Version 2.9.2
## - whole review of the MOD script itself
## - tested with EM 0.3.0 on a fresh phpBB 2.0.22 install (localhost)
##
## 2007-01-14 - Version 2.9.0a
## - .. (that's a huge review)
## - minor text amending into the install script
## - DB installer updated to the latest of 05-Jan-2007: 72639 entries instead of (71978 of Nov-2006) ^_^
## - slightly modified the Main ISO3661 Table (ip_id (INT) = from 5 to 6), why? Don't worry.
## -
## - external lang file updated o_O, it's also ready for future Bots implementation..
## .. (stay tuned so, I'm at 95%) and more.
## -
## - slightly modified the admin/admin_ip_cf_old_db_eraser part..
## ..(it will not erase your new entries anymore)
## -
## - slightly modified the admin/admin_ip_cf_ip_manager part accordingly to admin/admin_ip_cf_old_db_eraser
## - added 'secondary user flag of choice' in memberlist, view_topic, view_profile, edit_profile
## -
## - added 'secondary user flag of choice' ACP Management side for Editing/Users Management..
## ..(inspiration and part of code comes from Country/Location MOD by Nuttzy99/ycl6..
## ..the compatibility with that MOD has been kept, so also that MOD can be installed.. I hope so ^_^).
## -
## - 'past 24hrs guests flag' code completely re-written in includes/today_userlist.php..
## .. (it doesn't use phpBB's session lenght anymore but its own Logic if any.. LOL)
## -
## - added 4 new functions for encode/decode IPS from/to Decimals/Hexs/Quads..
## .. and some of them they are compatibles also with PHP3 ^_^
## -
## - added two new Tables to the DB ('past 24hrs guests' and 'secondary user flags')
##
## 2007-01-12 - Version 2.9.0
## - some code review/clean-up here and there ^_^
## - modified the Main ISO3661 Table (ip_id indexed and autoincremented, plus Prefixes)
## - slightly modified the automated DB installer to fit DB modifications
## - external lang file updated to reflect all the new additions. o_O
##
## 2007-01-05 - Version 2.8.0
## - installation script completely reviewed
## - implemented existent lang variables for today userlist
## - added a message_die()
##
## 2007-01-03 - Version 2.7.8
## - added 'past Xhrs guests flag'
## ...(the time is based on the phpBB's session lenght time (ACP configuration) at the present time
## - external lang file updated to reflect all the new additions. o_O
## - added 'Update Session on Page Change MOD 1.0.0 (by markus_petrux)'
##
## 2006-12-30 - Version 2.7.6
## - fixed a small bug in includes/usercp_viewprofile.php for default Avatar (logic)
## - added missing flags in PMs (in the main body)
##
## MOD History:
##
## 2006-12-26 - Version 2.7.4
## - added Log IP on registration (thx TerraFrost)
## - fixed bug in index.php: 'flag of the newest user shows as "blue" till the log-in' ..
## .. now works correctly and displays the IP on registration's Flag.
## - Default IP Avatar now works only for activated users in view_profile, else none.
## - external lang file updated to reflect all the new additions. o_O
## - the Logic for admin/ip_cf_ip_manager.php has been recoded.
## - minor hard-coded texts fixed.
## - tested on phpBB 2.0.22 with EM 0.3.0.
## - The MOD passed the MOD pre-validation process.
##
## 2006-12-25 - Version 2.7.2
## - added flags in search.php/tpls (also for guests) ^_°
## - removed redundant code from ACP IP CF Tools (4 php files)
## - tested on phpBB 2.0.22 with EM 0.3.0
## - MOD installation script updated and tested...
##
## 2006-12-24 - Version 2.7.0
## - added flags in topic_review.php/tpl
## - added flags in privmsg.php (PMs .. no guests here though ^_°)
## - added flags in groupcp.php (yawnn.. /me need a rest ;-) )
## - fixed a bug in forum.php (topic author and last poster flags for guests) O_O
## .... in these spam-days, you know.. better guests to have a flag ...
## - fixed a bug in index.php (last poster flag for guests) O_O (see above comment)
## - ACP IP CF Tools TPLs (4) reviewed.
## - ACP IP CF Tools PHPs (4) reviewed.
## - tested on phpBB 2.0.22 with EM 0.3.0.
## - whole code check-in (like airports ^_^)
## - external lang file updated to reflect all the additions. o_O
##
## 2006-12-21 - Version 2.6.0
## - install/database_update files have been replaced with the new ones
## .... credits: markus_petrux was there in 2005) .. thank you.
## .... FIXed the PHP's integer 'bug' on it (a workaround though).
## - added ACP IP CF Tools - Old IPs Table Eraser and Optimizer.
## - ACP IP CF Tools TPLs (4) reviewed and code cleaned up.
## - ACP IP CF Tools PHPs (4) reviewed and code cleaned up.
## - FIXed a bug present into admin/admin_ip_cf_ip_manager.php
## - Introducing "LOCALHOST" flags (rude IMG versions though) for those whom have installed
## .... this MOD on their own PCs (127.0.0.1).
## - minor hard-coded texts fixed.
## - external lang file updated to reflect all the additions.
## - external lang file inclusion has been improved: if it's missing will show a nice error window now. O_O
## - MOD installation script amended.
## - tested on phpBB 2.0.21 with EM 0.3.0.
## - xHTML 1.0 Transitional Compliance checked.
## - General check of TPLs and amend.
## - Removed the redundant PHP code from usercp_register.php
## - repackaged.
##



old post wrote: ZIPfile updated, corrected a little typo.
See first post for link.
Last edited by 3Di on Thu Mar 20, 2008 9:18 pm, edited 7 times in total.
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
tahoebuff
Registered User
Posts: 1429
Joined: Tue Jul 20, 2004 12:33 am
Location: Nevada
Name: Michael
Contact:

Post by tahoebuff »

3Di wrote: ZIPfile updated, corrected a little typo.
See first post for link.


This works very nicely...although, I had problems with EasyMod and had to do the changes by hand. A little more work than I anticipated tonight :)

By the way, is the typo something I will need to change since I used your prior zip?

Tahoebuff
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Post by 3Di »

tahoebuff wrote:
3Di wrote:ZIPfile updated, corrected a little typo.
See first post for link.


This works very nicely...although, I had problems with EasyMod and had to do the changes by hand. A little more work than I anticipated tonight :)

By the way, is the typo something I will need to change since I used your prior zip?

Tahoebuff


Hi Tahoebuff,
the typo was a mismatch error in the install text, noticed by BitterDream (SubSilver instead of subSilver), occurrences all amended, so.

The code remains the same, as a matter of fact. ;)
Greets.
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
deny
Registered User
Posts: 565
Joined: Wed May 14, 2003 9:14 am
Contact:

Post by deny »

Is it SQL queries high addons?
Example if you have 50 members and guest from different country on your board should SQL queries raise on index page for example +50 or...?

Thanks
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Post by 3Di »

deny wrote: Is it queries high addons?
Example if you have 50 members and guest from different country on your board should queries raise on index page for example +50 or...?

Thanks


That depends on the phpBB core code, the MOD query the phpBB's DB fields.
The maximum users i had online was 15. lol..
Nightwatch DL (with the CH version of this MOD, available in my Forum) reached the maximum (afaik = 50) and some dots ( . ) have been show at the end of the stats box (dots only viewable with FireFox engines) indicating that really the visits count was more than 50.

here's an image of the stats in my CH Forum
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
deny
Registered User
Posts: 565
Joined: Wed May 14, 2003 9:14 am
Contact:

Post by deny »

ok but my question is more does it mean that one visitors is one query more (because of flag) and how is it handle by your mod?
If board index have for example SQL queries of 10.Does it mean that with your mod it should raise because of flag for one query per visitor or not?
More queries on high traffic board should mean slowing of execution of queries and higher pressure on database what is not good at all.
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Post by 3Di »

deny wrote: ok but my question is more does it mean that one visitors is one query more (because of flag) and how is it handle by your mod?
If board index have for example SQL queries of 10.Does it mean that with your mod it should raise because of flag for one query per visitor or not?
More queries on high traffic board should mean slowing of execution of queries and higher pressure on database what is not good at all.


Queries on database are done only for guests.
That's it, afaik, I'll ask some more info to Nightwacht DL about that, due to the fact the related code was written by him.

Thank you..
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Post by 3Di »

deny wrote: ok but my question is more does it mean that one visitors is one query more (because of flag) and how is it handle by your mod?
If board index have for example SQL queries of 10.Does it mean that with your mod it should raise because of flag for one query per visitor or not?
More queries on high traffic board should mean slowing of execution of queries and higher pressure on database what is not good at all.


Oky, that's it:
Nightwatch wrote: 1) For multi-language (or non-english boards) there are quite a few additional queries to retrieve the right language name for countries. In a future version we should be able to alter the existing SQL query in stead of making a new one. In theory we should be able toremove all seperate language queries by making them unions in stead of current SQL queries.

2) For English boards, one additional query whenever a session is created, it has to search a rather large index (IP ranges), so will have a noticable effect on very, very big boards. Regular viewing of the index page should not, if I recall correctly, add a query even for guests. Guests already have existing sessions, and session data are pulled anyway, so the impact of this mod on big boards should be minimal, but on exceptionally big boards, noticable... just barely ;-)

Anyway, that's just my opinion from what I remember and considering I have no experience with running anything big, just DarkLight ;-)


Consider that Darklight Board have more than 1.100 users and about 600 users online daily.

Greets
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
jrolson
Registered User
Posts: 968
Joined: Wed Jan 05, 2005 1:53 am
Location: U.S.

Post by jrolson »

Image

How would I remove the flags from the who's online block?
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Post by 3Di »

jrolson wrote: How would I remove the flags from the who's online block?


tell me..
are you using phpBB 2.0.16 and pre-modded files or what?

:?:
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
jrolson
Registered User
Posts: 968
Joined: Wed Jan 05, 2005 1:53 am
Location: U.S.

Post by jrolson »

Im using 2.0.16 and no premodded files.

Where is the code for the flags on the who is online block?
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Post by 3Di »

jrolson wrote: Im using 2.0.16 and no premodded files.

Where is the code for the flags on the who is online block?


templates/subSilver/viewonline_body.tpl
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
jrolson
Registered User
Posts: 968
Joined: Wed Jan 05, 2005 1:53 am
Location: U.S.

Post by jrolson »

Thats for the whos online page. Im talking about the whos online block on the bottom of the index.php
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Post by 3Di »

jrolson wrote: Thats for the whos online page. Im talking about the whos online block on the bottom of the index.php


iincludes/page_header.php
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
Locked

Return to “[2.0.x] MODs in Development”