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.

 

GeoIP redirection once

GeoIP redirection once

I have not used metamodpro much ( just bought 1 hours ago ) . my first challenge is redirect use only first time based on geoIP . I could manage to redirect user to another url . but that seems forever . I want user should redirected only he first time visit ( on an active session ) .

Is it possible in metamodpro?

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

Re: GeoIP redirection once

Hi Rondu,

This is possible to do using session variables. You could do something like this:

session_start();
/* set a different "instance name" for each MetaMod you use in this way */
$instance_name = "redirection1";
if (!@$_SESSION[$instance_name] and $fromCountryId == 'FR' ) {
  $_SESSION[$instance_name] = true;
  JFactory::getApplication()->redirect( "http://www.example.com/fr_pricing" );
}

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:
1667
Total Polls:
6
Total Posts:
5909
Posts this week:
1
User Info:
 
Total Users:
10117
Newest User:
prediksibolajitu
Members Online:
1
Guests Online:
136

Online: 
prediksibolajitu

Forum Legend:

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