Welcome to the MetaMod and Chameleon Support Forums.

Before posting, please check out the FAQs.

helpme

 

Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.

 

IP Redirect Issue

IP Redirect Issue

Hello all,

Currently using Joomla 1.6.5 (I want to upgrade but not my call) and using MetaMod v3.7, 2011-10-03. It's for www.piratespress.com.

Currently have the rule set:
if ( $geoip->"EU" ) return 367;
if ( $geoip->"NA" ) return 315;

However, it doesn't work as I'd like and the same page (315) shows up no matter what the location.

Any ideas/suggestions? I screenshot the settings in the module manager and it's identical to what's in the menu manager for MetaMod. You can download them here - http://www.piratespressrecords.com/MetaMod.zip

Thanks!

christianwagner
Beginner Modder
ranks
useravatar
Offline
1 Posts
Administrator has disabled public posting

Re: IP Redirect Issue

Hi Christian,

the syntax is slightly wrong. I guess from the example you gave that you want to detect "continent" rather than country. In that case, ensure you do the following:

1 - use the GeoLiteCity database rather than the GeoIPCountry database.
2 - the following PHP:

if ( $geoip->continent_code == "EU" ) return 367;
if ( $geoip->continent_code == "NA" ) return 315;

Hope that helps,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3312 Posts
User info in posts
Administrator has disabled public posting

Board Info

Board Stats:
 
Total Topics:
1666
Total Polls:
6
Total Posts:
5909
Dormant:
User Info:
 
Total Users:
10091
Newest User:
lamanaudio
Members Online:
3
Guests Online:
138


Forum Legend:

 Topic
 New
 Locked
 Sticky
 Active
 New/Active
 New/Locked
 New Sticky
 Locked/Active
 Active/Sticky
 Sticky/Locked
 Sticky/Active/Locked