GT – Geo Targeting
Edit (9/12/2010): Plugin has some known compatibility issues. They’ll be fixed in a week as I am very busy right now.
Edit (03/10/2011): I will update the plugin in a week and will use classes which will make the plugin more compatible when a conflicting plugin has been installed.
GT – Geo-Targeting (GEO target) content based on user’s country.
Features
* Shortcodes for use in content.
* Show the content to users in multiple countries.
* Hide the content from users in multiple countries.
* Show a note to users who are not able to see the content.
* PHP Template tags also available for use.
Usage
Shortcodes
There are 2 shortcodes available in the current version.
Shortcode #1 :- [geo-in]
Show content to users from country(ies).
It takes the following parameters: country, note.
Country(parameter): It takes the name(s) of the country(ies) to show the content to.
[geo-in country="us"]test[/geo-in]
or,
[geo-in country="United States"]test[/geo-in]
To add more than one country, you have to separate them by comma. Like below:
[geo-in country="us,gb,Australia"]test[/geo-in]
Note(parameter): It adds a note to be displayed to users who cannot see the content. Default is “Content not available for your country”.
[geo-in country="us" note="Non-US are not allowed"]test[/geo-in]
will display: “Non-US are not allowed” to users who are not allowed to see the content.
or,
[geo-in country="us,au" note="Non-US & non-AU are not allowed"]test[/geo-in]
Shortcode #2 :- [geo-out]
Show content from users in country(ies).
It takes the following parameters: country, note.
Country(parameter): It takes the name(s) of the country(ies) to hide the content from.
[geo-out country="us"]test[/geo-out]
or,
[geo-out country="United States"]test[/geo-out]
To add more than one country, you have to separate them by comma. Like below:
[geo-out country="us,gb,Australia"]test[/geo-out]
Note(parameter): It adds a note to be displayed to users who cannot see the content. Default is “Content not available for your country”.
[geo-out country="us" note="US people are not allowed"]test[/geo-out]
will display: “US people are not allowed” to users who are not allowed to see the content.
or,
[geo-out country="us,au" note="US & non-AU are not allowed"]test[/geo-out]
Template Tags
#1. WPGeo_IsFromCountry()
Checks if user is from a list of given countries. Takes one string parameter. Separate more than one countries by comma.
Example:
<?php if(WPGeo_IsFromCountry('us') == true)
{
//statements here
}
?>or,
<?php if(WPGeo_IsFromCountry('United States') == true)
{
//statements here
}
?>or,
<?php if(WPGeo_IsFromCountry('us,au,gb') == true)
{
//statements here
}
?>or,
<?php if(WPGeo_IsFromCountry('United States,au,gb,India') == true)
{
//statements here
}
?>#2. WPGeo_IsNotFromCountry()
Checks if user is not from a list of given countries. Takes one string parameter. Separate more than one countries by comma.
Example:
<?php if(WPGeo_IsNotFromCountry('us') == true)
{
//statements here
}
?>or,
<?php if(WPGeo_IsNotFromCountry('United States') == true)
{
//statements here
}
?>or,
<?php if(WPGeo_IsNotFromCountry('us,au,gb') == true)
{
//statements here
}
?>or,
<?php if(WPGeo_IsNotFromCountry('United States,au,gb,India') == true)
{
//statements here
}
?>
{ 35 comments… read them below or add one }
This is very good. Something I can definitely use.
For the template tags, will an if else statement work? For example:
Yes, an if else statement will work. Just add an else {} or elseif{} to the codes.
hi there .thanks for plugin, Does anybody know if tis script is compatible with WordPress 2.9 ? Thanks in advance for any help on this! Regards
Plugin is compatible with WP 2.9.
Hello,
Your plugin looks great
However, I would like to ask you, would you know if your plugin would be compatible with the wp-supercache plugin ?
Or would the wp-supercache plugin still take over, randomly serving pages to the visitors no matter where they may come from, turning the advantages of your GT plugin to naught ?
I experienced this problem with the wp-ban plugin, the supercache plugin would serve the “you’re banned” pages to random persons instead of the banned persons, for instance :-/
Thanks a lot if you can tell me
Oliver
Hello,
Plugin is currently incompatible with WP Super Cache, but I might add the compatibility later. I’ll have to dig into WP Super Cache for that.
Hey Pranav
Installed your Plugin on my football site and now I can happily push the right banners at the right segmented visitors. yeehaw. Step #1 in my CRO efforts. Thanks for this, and maybe you should add a paypal donate button to your site – I’m sure a few webmasters would buy you a few beers/orange juices/tipple of your choice
Thanks again
Niall
Plugin is working great! Is there any way I can make the plugin output the users country code? Like in “your country = US”?
Thanks,
Hans
Great plugin..please keep updating it for wordpress 3.0..
one question however, could you provide a list of short codes for all the countries??
Sure, I’ll do that today.
When I Install and update the plugin this is what I get :
“Plugin failed to reactivate due to a fatal error”
What to do now ?
Can you paste the error here?
hi, any updates on the list of shortcodes for all the countries??
can this work with continents?
Great plug in – is there any way that I can hack this lat/long for cities in the usa?
Hey, is there a list anywhere of the exact country codes etc – like a reference we can go off when assigning what countries are allowed / disallowed (even if you just made a post with the list).
btw great plugin its awesome
Is there any way to get this working in the text widget?
Great just what I was looking for
Hi – is there any way I can selectively display a widget dependent on country code?
Thanks
Would it be possible to have the countries listed in the Edit Post area so all a user has to do is check they boxes and click apply to have the shortcode created and inserted into the post?
I realize customization like this would require some extra coding and I’m willing to talk price for customization of the plugin.
Thanks,
Jerry
Hi,
Fantastic plug-in just what I have been looking for, quick query though I want to display one version to people from the UK and the other version to people from the US, at the moment I can do both but I get a message for the other saying “Content not available for your country”, is there any way where you can have just nothing appear if they come from the other county.
Thanks,
Neil
Saying that it isnt currently working for me at all, if I use
[geo-in country="uk"]test UK[/geo-in] and I am in the UK I should see “Test UK”
All I see is “Content not available for your country”
Please help,
Thanks
Hey there trying to get this working – can you see what I am doing wrong here?
Basically I have a bonus bar (on new site – not live yet) and I want to geotarget the bonuses to show usa bonuses if they are usa and if not display the rest.
I put this.
<?php if(WPGeo_IsFromCountry('us') == true)
{ echo' <img src="/images/providers/tables_usabookie.png” alt=”" />$5000
Match Bonus‘;
} else {
echo’ <img src="/images/providers/tables_internationalbookie.png” alt=”" />$5000
Match Bonus ‘;
}
?>
Does that look right? or am I doing something wrong there.
Neil, put the codes textarea in the html section. Probably, you putted in visual mode and “code” tag executed.
Does anyone know how to use this to as a kind of page redirect.
For example instead of showing different text or a hello message is shows a different page.
For example:
if I have one page called ‘home’ and another called ‘homeUsa’ and want to use this to do a redirect so when the user goes to the ‘home’ page and are from the USA they will be sent to ‘homeUsa’.
I am trying this by creating my own page template file and using the if.. else statement at the start of the template but I cant seem to get it working.
thanks for any help
Just solved my own problem.
I made a special page template for the page I want to redirect from and added the following lines after the header tag:
Where 31 is the page ID of the page I want USA’s visitors to go to.
Sweet!
Oh you don’t need the $post = bit just:
Can you please publish the country names/codes list?
Please ignore the previous comment… I found the codes…
‘AN’ ‘AND’ ‘Andorra’ ‘Andorra’
‘AR’ ‘ARE’ ‘United Arab Emirates’ ‘United Arab Emirates’
‘AF’ ‘AFG’ ‘Afghanistan’ ‘Afghanistan’
‘AT’ ‘ATG’ ‘Antigua and Barbuda’ ‘Antigua and Barbuda’
‘AI’ ‘AIA’ ‘Anguilla’ ‘Anguilla’
‘AL’ ‘ALB’ ‘Albania’ ‘Albania’
‘AR’ ‘ARM’ ‘Armenia’ ‘Armenia’
‘AN’ ‘ANT’ ‘Netherlands Antilles’ ‘Netherlands Antilles’
‘AG’ ‘AGO’ ‘Angola’ ‘Angola’
‘AT’ ‘ATA’ ‘Antarctica’ ‘Antarctica’
‘AR’ ‘ARG’ ‘Argentina’ ‘Argentina’
‘AS’ ‘ASM’ ‘American Samoa’ ‘American Samoa’
‘AU’ ‘AUT’ ‘Austria’ ‘Austria’
‘AU’ ‘AUS’ ‘Australia’ ‘Australia’
‘AB’ ‘ABW’ ‘Aruba’ ‘Aruba’
‘AZ’ ‘AZE’ ‘Azerbaijan’ ‘Azerbaijan’
‘BI’ ‘BIH’ ‘Bosnia and Herzegovina’ ‘Bosnia and Herzegovina’
‘BR’ ‘BRB’ ‘Barbados’ ‘Barbados’
‘BG’ ‘BGD’ ‘Bangladesh’ ‘Bangladesh’
‘BE’ ‘BEL’ ‘Belgium’ ‘Belgium’
‘BF’ ‘BFA’ ‘Burkina Faso’ ‘Burkina Faso’
‘BG’ ‘BGR’ ‘Bulgaria’ ‘Bulgaria’
‘BH’ ‘BHR’ ‘Bahrain’ ‘Bahrain’
‘BD’ ‘BDI’ ‘Burundi’ ‘Burundi’
‘BE’ ‘BEN’ ‘Benin’ ‘Benin’
‘BM’ ‘BMU’ ‘Bermuda’ ‘Bermuda’
‘BR’ ‘BRN’ ‘Brunei Darussalam’ ‘Brunei Darussalam’
‘BO’ ‘BOL’ ‘Bolivia’ ‘Bolivia’
‘BR’ ‘BRA’ ‘Brazil’ ‘Brazil’
‘BH’ ‘BHS’ ‘Bahamas’ ‘Bahamas’
‘BT’ ‘BTN’ ‘Bhutan’ ‘Bhutan’
‘BV’ ‘BVT’ ‘Bouvet Island’ ‘Bouvet Island’
‘BW’ ‘BWA’ ‘Botswana’ ‘Botswana’
‘BL’ ‘BLR’ ‘Belarus’ ‘Belarus’
‘BL’ ‘BLZ’ ‘Belize’ ‘Belize’
‘CA’ ‘CAN’ ‘Canada’ ‘Canada’
‘CC’ ‘CCK’ ‘Cocos (Keeling) Islands’ ‘Cocos (Keeling) Islands’
‘CA’ ‘CAF’ ‘Central African Republic’ ‘Central African Republic’
‘CO’ ‘COG’ ‘Congo’ ‘Congo’
‘CH’ ‘CHE’ ‘Switzerland’ ‘Switzerland’
‘CO’ ‘COK’ ‘Cook Islands’ ‘Cook Islands’
‘CH’ ‘CHL’ ‘Chile’ ‘Chile’
‘CM’ ‘CMR’ ‘Cameroon’ ‘Cameroon’
‘CH’ ‘CHN’ ‘China’ ‘China’
‘CO’ ‘COL’ ‘Colombia’ ‘Colombia’
‘CR’ ‘CRI’ ‘Costa Rica’ ‘Costa Rica’
‘SC’ ‘SCG’ ‘Serbia and Montenegro’ ‘Serbia and Montenegro’
‘CU’ ‘CUB’ ‘Cuba’ ‘Cuba’
‘CP’ ‘CPV’ ‘Cape Verde’ ‘Cape Verde’
‘CX’ ‘CXR’ ‘Christmas Island’ ‘Christmas Island’
‘CY’ ‘CYP’ ‘Cyprus’ ‘Cyprus’
‘CZ’ ‘CZE’ ‘Czech Republic’ ‘Czech Republic’
‘DE’ ‘DEU’ ‘Germany’ ‘Germany’
‘DJ’ ‘DJI’ ‘Djibouti’ ‘Djibouti’
‘DN’ ‘DNK’ ‘Denmark’ ‘Denmark’
‘DM’ ‘DMA’ ‘Dominica’ ‘Dominica’
‘DO’ ‘DOM’ ‘Dominican Republic’ ‘Dominican Republic’
‘DZ’ ‘DZA’ ‘Algeria’ ‘Algeria’
‘EC’ ‘ECU’ ‘Ecuador’ ‘Ecuador’
‘ES’ ‘EST’ ‘Estonia’ ‘Estonia’
‘EG’ ‘EGY’ ‘Egypt’ ‘Egypt’
‘ES’ ‘ESH’ ‘Western Sahara’ ‘Western Sahara’
‘ER’ ‘ERI’ ‘Eritrea’ ‘Eritrea’
‘ES’ ‘ESP’ ‘Spain’ ‘Spain’
‘ET’ ‘ETH’ ‘Ethiopia’ ‘Ethiopia’
‘FI’ ‘FIN’ ‘Finland’ ‘Finland’
‘FJ’ ‘FJI’ ‘Fiji’ ‘Fiji’
‘FL’ ‘FLK’ ‘Falkland Islands (Malvinas)’ ‘Falkland Islands (Malvinas)’
‘FS’ ‘FSM’ ‘Micronesia’ ‘Micronesia’
‘FR’ ‘FRO’ ‘Faroe Islands’ ‘Faroe Islands’
‘FR’ ‘FRA’ ‘France’ ‘France’
‘CI’ ‘CIV’ ‘Cote D’ivoire’ ‘Ivory Coast’
‘GA’ ‘GAB’ ‘Gabon’ ‘Gabon’
‘GR’ ‘GRD’ ‘Grenada’ ‘Grenada’
‘GE’ ‘GEO’ ‘Georgia’ ‘Georgia’
‘GU’ ‘GUF’ ‘French Guiana’ ‘French Guiana’
‘GH’ ‘GHA’ ‘Ghana’ ‘Ghana’
‘GI’ ‘GIB’ ‘Gibraltar’ ‘Gibraltar’
‘GR’ ‘GRL’ ‘Greenland’ ‘Greenland’
‘GM’ ‘GMB’ ‘Gambia’ ‘Gambia’
‘GI’ ‘GIN’ ‘Guinea’ ‘Guinea’
‘GL’ ‘GLP’ ‘Guadeloupe’ ‘Guadeloupe’
‘GN’ ‘GNQ’ ‘Equatorial Guinea’ ‘Equatorial Guinea’
‘GR’ ‘GRC’ ‘Greece’ ‘Greece’
‘SG’ ‘SGS’ ‘South Georgia and the South Sandwich Islands’ ‘S. Georgia and S. Sandwich Isls.’
‘GT’ ‘GTM’ ‘Guatemala’ ‘Guatemala’
‘GU’ ‘GUM’ ‘Guam’ ‘Guam’
‘GN’ ‘GNB’ ‘Guinea-Bissau’ ‘Guinea-Bissau’
‘GU’ ‘GUY’ ‘Guyana’ ‘Guyana’
‘HK’ ‘HKG’ ‘Hong Kong’ ‘Hong Kong’
‘HM’ ‘HMD’ ‘Heard Island and Mcdonald Islands’ ‘Heard and McDonald Islands’
‘HN’ ‘HND’ ‘Honduras’ ‘Honduras’
‘HR’ ‘HRV’ ‘Croatia (Hrvatska)’ ‘Croatia (Hrvatska)’
‘HT’ ‘HTI’ ‘Haiti’ ‘Haiti’
‘HU’ ‘HUN’ ‘Hungary’ ‘Hungary’
‘ID’ ‘IDN’ ‘Indonesia’ ‘Indonesia’
‘IR’ ‘IRL’ ‘Ireland’ ‘Ireland’
‘IS’ ‘ISR’ ‘Israel’ ‘Israel’
‘IN’ ‘IND’ ‘India’ ‘India’
‘IO’ ‘IOT’ ‘British Indian Ocean Territory’ ‘British Indian Ocean Territory’
‘IR’ ‘IRQ’ ‘Iraq’ ‘Iraq’
‘IR’ ‘IRN’ ‘Iran Islamic Republic of’
‘IS’ ‘ISL’ ‘Iceland’ ‘Iceland’
‘IT’ ‘ITA’ ‘Italy’ ‘Italy’
‘JA’ ‘JAM’ ‘Jamaica’ ‘Jamaica’
‘JO’ ‘JOR’ ‘Jordan’ ‘Jordan’
‘JP’ ‘JPN’ ‘Japan’ ‘Japan’
‘KE’ ‘KEN’ ‘Kenya’ ‘Kenya’
‘KG’ ‘KGZ’ ‘Kyrgyzstan’ ‘Kyrgyzstan’
‘KH’ ‘KHM’ ‘Cambodia’ ‘Cambodia’
‘KI’ ‘KIR’ ‘Kiribati’ ‘Kiribati’
‘CO’ ‘COM’ ‘Comoros’ ‘Comoros’
‘KN’ ‘KNA’ ‘Saint Kitts and Nevis’ ‘Saint Kitts and Nevis’
‘PR’ ‘PRK’ ‘Korea Democratic People’s Republic of (North)’
‘KO’ ‘KOR’ ‘Korea Republic of (South)’
‘KW’ ‘KWT’ ‘Kuwait’ ‘Kuwait’
‘CY’ ‘CYM’ ‘Cayman Islands’ ‘Cayman Islands’
‘KA’ ‘KAZ’ ‘Kazakhstan’ ‘Kazakhstan’
‘LA’ ‘LAO’ ‘Lao People’s Democratic Republic’ ‘Laos’
‘LB’ ‘LBN’ ‘Lebanon’ ‘Lebanon’
‘LC’ ‘LCA’ ‘Saint Lucia’ ‘Saint Lucia’
‘LI’ ‘LIE’ ‘Liechtenstein’ ‘Liechtenstein’
‘LK’ ‘LKA’ ‘Sri Lanka’ ‘Sri Lanka’
‘LB’ ‘LBR’ ‘Liberia’ ‘Liberia’
‘LS’ ‘LSO’ ‘Lesotho’ ‘Lesotho’
‘LT’ ‘LTU’ ‘Lithuania’ ‘Lithuania’
‘LU’ ‘LUX’ ‘Luxembourg’ ‘Luxembourg’
‘LV’ ‘LVA’ ‘Latvia’ ‘Latvia’
‘LB’ ‘LBY’ ‘Libyan Arab Jamahiriya’ ‘Libya’
‘MA’ ‘MAR’ ‘Morocco’ ‘Morocco’
‘MC’ ‘MCO’ ‘Monaco’ ‘Monaco’
‘MD’ ‘MDA’ ‘Moldova’ ‘Moldova’
‘MD’ ‘MDG’ ‘Madagascar’ ‘Madagascar’
‘MH’ ‘MHL’ ‘Marshall Islands’ ‘Marshall Islands’
‘MK’ ‘MKD’ ‘Macedonia the Former Yugoslav Republic of’
‘ML’ ‘MLI’ ‘Mali’ ‘Mali’
‘MM’ ‘MMR’ ‘Myanmar’ ‘Burma (Myanmar)’
‘MN’ ‘MNG’ ‘Mongolia’ ‘Mongolia’
‘MO’ ‘MAC’ ‘Macau’ ‘Macau’
‘MN’ ‘MNP’ ‘Northern Mariana Islands’ ‘Northern Mariana Islands’
‘MT’ ‘MTQ’ ‘Martinique’ ‘Martinique’
‘MR’ ‘MRT’ ‘Mauritania’ ‘Mauritania’
‘MS’ ‘MSR’ ‘Montserrat’ ‘Montserrat’
‘ML’ ‘MLT’ ‘Malta’ ‘Malta’
‘MU’ ‘MUS’ ‘Mauritius’ ‘Mauritius’
‘MD’ ‘MDV’ ‘Maldives’ ‘Maldives’
‘MW’ ‘MWI’ ‘Malawi’ ‘Malawi’
‘ME’ ‘MEX’ ‘Mexico’ ‘Mexico’
‘MY’ ‘MYS’ ‘Malaysia’ ‘Malaysia’
‘MZ’ ‘MOZ’ ‘Mozambique’ ‘Mozambique’
‘NA’ ‘NAM’ ‘Namibia’ ‘Namibia’
‘NC’ ‘NCL’ ‘New Caledonia’ ‘New Caledonia’
‘NE’ ‘NER’ ‘Niger’ ‘Niger’
‘NF’ ‘NFK’ ‘Norfolk Island’ ‘Norfolk Island’
‘NG’ ‘NGA’ ‘Nigeria’ ‘Nigeria’
‘NI’ ‘NIC’ ‘Nicaragua’ ‘Nicaragua’
‘NL’ ‘NLD’ ‘Netherlands’ ‘Netherlands’
‘NO’ ‘NOR’ ‘Norway’ ‘Norway’
‘NP’ ‘NPL’ ‘Nepal’ ‘Nepal’
‘NR’ ‘NRU’ ‘Nauru’ ‘Nauru’
‘NT’ ‘NTZ’ ‘Neutral Zone’ ‘Neutral Zone’
‘NI’ ‘NIU’ ‘Niue’ ‘Niue’
‘NZ’ ‘NZL’ ‘New Zealand’ ‘New Zealand (Aotearoa)’
‘OM’ ‘OMN’ ‘Oman’ ‘Oman’
‘PA’ ‘PAN’ ‘Panama’ ‘Panama’
‘PE’ ‘PER’ ‘Peru’ ‘Peru’
‘PY’ ‘PYF’ ‘French Polynesia’ ‘French Polynesia’
‘PN’ ‘PNG’ ‘Papua New Guinea’ ‘Papua New Guinea’
‘PH’ ‘PHL’ ‘Philippines’ ‘Philippines’
‘PA’ ‘PAK’ ‘Pakistan’ ‘Pakistan’
‘PO’ ‘POL’ ‘Poland’ ‘Poland’
‘SP’ ‘SPM’ ‘Saint Pierre and Miquelon’ ‘St. Pierre and Miquelon’
‘PC’ ‘PCN’ ‘Pitcairn’ ‘Pitcairn’
‘PR’ ‘PRI’ ‘Puerto Rico’ ‘Puerto Rico’
‘PR’ ‘PRT’ ‘Portugal’ ‘Portugal’
‘PL’ ‘PLW’ ‘Palau’ ‘Palau’
‘PR’ ‘PRY’ ‘Paraguay’ ‘Paraguay’
‘QA’ ‘QAT’ ‘Qatar’ ‘Qatar’
‘RE’ ‘REU’ ‘Reunion’ ‘Reunion’
‘RO’ ‘ROU’ ‘Romania’ ‘Romania’
‘RU’ ‘RUS’ ‘Russian Federation’ ‘Russia’
‘RW’ ‘RWA’ ‘Rwanda’ ‘Rwanda’
‘SA’ ‘SAU’ ‘Saudi Arabia’ ‘Saudi Arabia’
‘SL’ ‘SLB’ ‘Solomon Islands’ ‘Solomon Islands’
‘SY’ ‘SYC’ ‘Seychelles’ ‘Seychelles’
‘SD’ ‘SDN’ ‘Sudan’ ‘Sudan’
‘SW’ ‘SWE’ ‘Sweden’ ‘Sweden’
‘SG’ ‘SGP’ ‘Singapore’ ‘Singapore’
‘SH’ ‘SHN’ ‘Saint Helena’ ‘St. Helena’
‘SV’ ‘SVN’ ‘Slovenia’ ‘Slovenia’
‘SJ’ ‘SJM’ ‘Svalbard and Jan Mayen Islands’ ‘Svalbard and Jan Mayen Islands’
‘SV’ ‘SVK’ ‘Slovakia’ ‘Slovak Republic’
‘SL’ ‘SLE’ ‘Sierra Leone’ ‘Sierra Leone’
‘SM’ ‘SMR’ ‘San Marino’ ‘San Marino’
‘SE’ ‘SEN’ ‘Senegal’ ‘Senegal’
‘SO’ ‘SOM’ ‘Somalia’ ‘Somalia’
‘SU’ ‘SUR’ ‘Suriname’ ‘Suriname’
‘ST’ ‘STP’ ‘Sao Tome and Principe’ ‘Sao Tome and Principe’
‘SL’ ‘SLV’ ‘El Salvador’ ‘El Salvador’
‘SY’ ‘SYC’ ‘Seychelles’ ‘Syria’
‘SW’ ‘SWZ’ ‘Swaziland’ ‘Swaziland’
‘TC’ ‘TCA’ ‘Turks and Caicos Islands’ ‘Turks and Caicos Islands’
‘TC’ ‘TCD’ ‘Chad’ ‘Chad’
‘AT’ ‘ATF’ ‘French Southern Territories’ ‘French Southern Territories’
‘TG’ ‘TGO’ ‘Togo’ ‘Togo’
‘TH’ ‘THA’ ‘Thailand’ ‘Thailand’
‘TJ’ ‘TJK’ ‘Tajikistan’ ‘Tajikistan’
‘TK’ ‘TKL’ ‘Tokelau’ ‘Tokelau’
‘TK’ ‘TKM’ ‘Turkmenistan’ ‘Turkmenistan’
‘TU’ ‘TUN’ ‘Tunisia’ ‘Tunisia’
‘TO’ ‘TON’ ‘Tonga’ ‘Tonga’
‘TL’ ‘TLS’ ‘Timor-Leste’ ‘East Timor’
‘TU’ ‘TUR’ ‘Turkey’ ‘Turkey’
‘TT’ ‘TTO’ ‘Trinidad and Tobago’ ‘Trinidad and Tobago’
‘TU’ ‘TUV’ ‘Tuvalu’ ‘Tuvalu’
‘TW’ ‘TWN’ ‘Taiwan’ ‘Taiwan’
‘TZ’ ‘TZA’ ‘Tanzania United Republic of’
‘UK’ ‘UKR’ ‘Ukraine’ ‘Ukraine’
‘UG’ ‘UGA’ ‘Uganda’ ‘Uganda’
‘GB’ ‘GBR’ ‘United Kingdom’ ‘United Kingdom’
‘US’ ‘USA’ ‘United States’ ‘United States’
‘UR’ ‘URY’ ‘Uruguay’ ‘Uruguay’
‘UZ’ ‘UZB’ ‘Uzbekistan’ ‘Uzbekistan’
‘VA’ ‘VAT’ ‘Vatican City State’ ‘Vatican City State (Holy See)’
‘VC’ ‘VCT’ ‘Saint Vincent and the Grenadines’ ‘Saint Vincent and the Grenadines’
‘VE’ ‘VEN’ ‘Venezuela’ ‘Venezuela’
‘VG’ ‘VGB’ ‘Virgin Islands British’
‘VI’ ‘VIR’ ‘Virgin Islands U.S.’
‘VN’ ‘VNM’ ‘Viet Nam’ ‘Viet Nam’
‘VU’ ‘VUT’ ‘Vanuatu’ ‘Vanuatu’
‘WL’ ‘WLF’ ‘Wallis and Futuna Islands’ ‘Wallis and Futuna Islands’
‘WS’ ‘WSM’ ‘Samoa’ ‘Samoa’
‘YE’ ‘YEM’ ‘Yemen’ ‘Yemen’
‘MY’ ‘MYT’ ‘Mayotte’ ‘Mayotte’
‘YU’ ‘YUG’ ‘Yugoslavia’ ‘Yugoslavia’
‘ZA’ ‘ZAF’ ‘South Africa’ ‘South Africa’
‘ZM’ ‘ZMB’ ‘Zambia’ ‘Zambia’
‘CD’ ‘COD’ ‘Congo Democratic Republic of the’
‘ZW’ ‘ZWE’ ‘Zimbabwe’ ‘Zimbabwe’
” ” ” ‘Asia-Pacific’
‘SR’ ‘SRB’ ‘Serbia’ ‘Republic of Serbia’
‘AX’ ‘ALA’ ‘Aland Islands’ ‘Aland Islands’
” ” ” ‘Europe’
” ” ” ‘Private’
‘PS’ ‘PSE’ ‘Palestinian Territory Occupied’
‘ME’ ‘MNE’ ‘Montenegro’ ‘Montenegro’
Thank you for a great plugin.
I am trying to use it on my test blog and it seams to be working. I am having a little problem though.
What I would like to do is to show a default ad on my posts and then geo target the other ads.
Let me explain. If I was using the php code then I would include a ‘else’ fuction to that code so it would show a ad to all other countries not listed in the geotargeting.
So if I was geo targeting america, UK, australia, france and then I would include a country like canada in the else section so all other countries would see the canadian ad. Example bellow:-
[geo-in country="us"]test for United States[/geo-in]
[geo-in country="uk"]test for United Kingdom[/geo-in]
Else
[geo-in country=]Show the ad that the rest of the world would see and not America or United Kingdom[/geo-in]
What I am basically saying is the ability to show a default ad if the countries are not in the geo target list.
Thanks in advance.
What is the latest on compatibility with 3.X please
Just wanted to say I’m using this plugin and you’re a very talented coder.
I hope I become as talented as you one day :p
To noel : i’m currtenly using WP 3.1 it’s fully compatible. Just a little problem with the note. It doesn’t display a custom note , only default.
Sorry, it’s working i’am a jackass !!
There seems to be a problem with the United kingdom code
Ive tried many different version of the code but it does not work at present. US codes work fine but in the UK i cant see content when using gb, gbr, uk, united kingdom etc
Thanks in advance,
Neil