Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.
- Index
- » Chameleon / ChameleonLite
- » ChameleonLite
- » Error when using GeoLite?
Error when using GeoLite?
Error when using GeoLite?
Hi,
I am trying to get Metatemplate to work. Starting very easy. I would like to use a different template for visitors from "Amsterdam" so I enable GeoLite.
But when I do that I get a warning in the front-end:
--- Warning: require_once(geoip.inc) [function.require-once]: failed to open stream: No such file or directory in **********/administrator/components/com_metatemplate/geoip/geoipcity.inc.php on line 33 ---
If I take a look in this directory there is no geoip.inc???
Can someone tell me what I do wrong???
Below is how I setup the Rule.
Re: Error when using GeoLite?
Oh, terribly sorry about this. I don't know how it slipped through quality control! I think it shows that not many people use this feature...
The quick fix for you is that in administrator/components/com_metatemplate/geoip/geoipcity.inc.php on line 33 you can add ".php" to "geoip.inc". The line should read:
require_once 'geoip.inc.php';
I'll make the fix and get the new version up for download as soon as possible.
Thanks for reporting it!
Best regards,
Stephen
Re: Error when using GeoLite?
By the way, there's also a small problem with the rule as you have it set up:
In the PHP box you check for a particular city - that's fine.
Beneath the PHP box, you have set the "default return" value to "true".
That means that if the PHP condition does not return the name of the template (gk_yourshop_new), it will return "true". This will cause the "succeed" action to be triggered. In the "succeed" action... you are again setting the "gk_yourshop_new" template.
The easiest thing to do is this:
if ($geoip->city == 'denbosch") return true;
... then set the default return value to "false"
... then in the succeed action, use the dropdown to set the gk_yourshop_new template
... and in the fail action, set an alternative template, or don't bother to set any template if you just want the default one to be used.
Cheers,
Stephen
Re: Error when using GeoLite?
Hi Stepen,
Sorry but ran in to another problem :-|
Warning: Unexpected character in input: ''' (ASCII=39) state=1 in /home/spellenwinkelde/html/spellenwinkeldenbosch.nl/components/com_metatemplate/helper.php(756) : eval()'d code on line 1
Re: Error when using GeoLite?
Re: Error when using GeoLite?
The new versions of MetaTemplate and MetaTemplate Pro now have the original problem with GeoLiteCity fixed.
They're available for download now.
Best regards,
Stephen
Re: Error when using GeoLite?
Hi stephen,
Back again, I have metatemplate setup now and its working exept for one thing.
I have set it up so that when a visitor is using the domeinname www.example.nl he will see template_one.
Other visitors from www.something.nl which is redirected to www.example.nl will see template_two but now there is a problem, the "Home" button is still refering to www.example.nl so when using the home button will bring the visitor back to www.example.nl with template_one.
I hope that i am making sens
I tryed to search the forum but could not find an answer.
Hope you can help me (again)
Thanks for your time!
Greetz Peterjan
- Index
- » Chameleon / ChameleonLite
- » ChameleonLite
- » Error when using GeoLite?
Board Info
- Board Stats:
- Total Topics:
- 1689
- Total Polls:
- 6
- Total Posts:
- 5943
- Posts this week:
- 2
- User Info:
- Total Users:
- 7642
- Newest User:
- mary26
- Members Online:
- 0
- Guests Online:
- 204
- Online:
- There are no members online
Forum Legend:
Topic
New
Locked
Sticky
Active
New/Active
New/Locked
New Sticky
Locked/Active
Active/Sticky
Sticky/Locked
Sticky/Active/Locked