Country Flags by IP Address [Deleted]

Your site has continuous MySQL error 28 problems. This alone can cause strange things to happen on a site. I suggest contacting your host to have those errors solved.

But, your problems were the permission settings for the social group add-on. It had nothing to do with the country flag add-on.
 
The flags are also not suitable for retina devices :-(
Neither are the ones you asked about. Both the flags included with the add-on and the flags you asked about are 72 DPI. Flags for retina would require 2 sprites sets, one for 2x and one standard. And I don't see that happening in the near future.
 
in fact, the quality of the flags are very poor in general, but this is only a cosmetic thing.
Eg, This is the flag of New Zealand:

R 2015-03-25 at 23.58.29.webp
and this is the normal:
R 2015-03-26 at 00.06.24.webp
the addon is awesome, would be great improve the quality of the flags if possible.
But seems is something tricky.
 
You aren't going to get a much better flag in a small size. The only way to do it would be to increase the size, which would allow for more detail. But then it would look totally out of place when it's shown in XF.

The one included in the add-on
actual.webp

The ones asked about
asked.webp
asked2.webp
 
The ones asked about
asked-png.102144

asked2-png.102145

Comparing to the other ones. These ones look better. Even if it's small. The first ones look like flags were done on paint.

In the other country flags add-on. I've always used the second pair you showed

16.webp
24.webp
32.webp


https://github.com/lafeber/world-flags-sprite/blob/master/images/flags16.png

https://github.com/lafeber/world-flags-sprite/blob/master/images/flags32.png


I like flags
 
Last edited:
Well, at this point all I can say is I have no intention of changing the flags. If and when I do it, it will be when I have time to construct a complete new set.
 
I'm not using this add-on yet but i just downloaded the files and the flags can be easily replaced if someone is not happy with them.

All i have to do is just put the flagsprites.png in photoshop and replace each individual flag. That's what i did with the other add-on.

It seems it's the same thing for this one. I will have to try it later.

I like flags
 
Anyone is able to replace the existing flags with that method. And you can even edit the css if you like to account for any changes.

But be aware that there are flags used by the add-on that don't exist in real life.
 
I'm not using this add-on yet but i just downloaded the files and the flags can be easily replaced if someone is not happy with them.

All i have to do is just put the flagsprites.png in photoshop and replace each individual flag. That's what i did with the other add-on.

It seems it's the same thing for this one. I will have to try it later.

I like flags

Would you mind sharing the sheet when you've done it?!
 
I'm wasn't planning on actually changing the flags as I plan to try this add-on just for testing purpose.

But if i change my mind. I will let you know.
 
All i have to do is just put the flagsprites.png in photoshop and replace each individual flag.
Would you mind sharing the sheet when you've done it?!
Well, to do that even is not necessary change all the flags, we can change just few of them or even only one. Eg. The New Zealand flag. Just to compare.
I'll do that later, let's see the result ;)
 
Last edited:
You need to resize the flag to 21 x 15 before pasting it into the existing sprite file. Check the CSS for the add-on for flag sizes.

Or completely rebuild the sprite file and re-do the CSS. But again, you need to account for the flags that are used by the add-on that do not exist in real life (ie: Satellite flag).
 
I've encountered a PHP error with this plugin + PHP 5.6.7 which completely broke my forums until I disabled it via config.php. I'm assuming the error has to do with the PHP addon 'bcmath' and when I try installing it on my CentOS 6.5 server, it gets an error as well.

Plugin Error:
Code:
Flags/Listener/Includes/Reader/Decoder.php on line 258, referer: http://IP Address/admin.php
[Tue Apr 07 03:42:15 2015] [error] [client IP Address] PHP Fatal error: Call to undefined function Countryflags\\Db\\Reader\\bcadd() in /var/www/html/library/Snog/CountryFlags/Listener/Includes/Reader/Decoder.php on line 258, referer: http://IP Address/admin.php
[Tue Apr 07 03:45:50 2015] [error] [client IP Address] PHP Fatal error: Call to undefined function Countryflags\\Db\\Reader\\bcadd() in /var/www/html/library/Snog/CountryFlags/Listener/Includes/Reader/Decoder.php on line 258
[Tue Apr 07 03:45:56 2015] [error] [client IP Address] PHP Fatal error: Call to undefined function Countryflags\\Db\\Reader\\bcadd() in /var/www/html/library/Snog/CountryFlags/Listener/Includes/Reader/Decoder.php on line 258

"IP Address" are IP's I blocked out for security purposes.

When installing php-bcmath:
Code:
[root@forums logs]# yum install php-bcmath
Loaded plugins: fastestmirror, replace
Loading mirror speeds from cached hostfile
* base: mirror-centos.hostingswift.com
* extras: mirror.oss.ou.edu
* updates: mirror.team-cymru.org
* webtatic: us-east.repo.webtatic.com
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package php-bcmath.x86_64 0:5.3.3-40.el6_6 will be installed
--> Processing Dependency: php-common(x86-64) = 5.3.3-40.el6_6 for package: php-bcmath-5.3.3-40.el6_6.x86_64
--> Running transaction check
---> Package php-common.x86_64 0:5.3.3-40.el6_6 will be installed
--> Processing Conflict: php56w-common-5.6.7-1.w6.x86_64 conflicts php-common < 5.5.0
--> Finished Dependency Resolution
Error: php56w-common conflicts with php-common-5.3.3-40.el6_6.x86_64
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
[root@forums logs]#

UPDATE - Fixed the bcmath problem. As shown in the logs, I have webtatic repo installed to get the latest PHP version. So when I install PHP modules, I need to do:

Code:
yum install php56w-bcmath

Which will install the module(s) correctly.
 
Last edited:
From the description of this add-on...

REQUIREMENTS:
cURL must be installed on server to update the GeoLite database.
BC Math for PHP must be installed on server and PHP must be configured to use BC Math.
If you've correctly installed BCMath and PHP is configured to use BCMath, any errors from the add-on should be gone. If you're still getting errors, then PHP isn't configured to use BCMatch
 
Last edited:
From the description of this add-on...


If you've correctly installed BCMath and PHP is configured to use BCMath, any errors from the add-on should be gone. If you're still getting errors, then PHP isn't configured to use BCMatch

Yeah I read the requirements. It was a mistake on my part since I'm using PHP 5.6.7 from webtatic's repo.
 
Back
Top Bottom