Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.
- Index
- » Chameleon / ChameleonLite
- » Chameleon
- » Need more than 4 permanent cookies
Need more than 4 permanent cookies
Need more than 4 permanent cookies
Hi,
I'm using Chameleon Pro in a manner similar to your video tutorial (receive a query string, set a cookie). I'm running into a problem, though, in that in the future I may need more than the 4 permanent cookies that you provide for.
Is there a way to get more permanent cookies (either via configuration, or via a future enhancement)?
Thanks for a great product!
Re: Need more than 4 permanent cookies
Hi Prickett,
That's a good question. I've been considering using a different control for setting/detecting cookies and session variables because of this limitation.
However, until I make that change in the future, you can set and detect cookies using the PHP boxes.
To set a cookie, use the PHP box in the SUCCEED or FAIL action:
$cookiename = "MT-1"; // customise!
$tenyears = 60*60*24*365*10;
setcookie( $cookiename, 1, time()+$tenyears, '/' );
To detect it, use this in the PHP box on the LEFT:
$cookiename = "MT-1"; // customise!
$cookie = JRequest::getInt($cookiename, 0, 'cookie');
if ($cookie > 0) return true;
Cheers,
Stephen
Re: Need more than 4 permanent cookies
Just to add to that, here's how to delete one of those cookies:
$cookiename = "MT-1"; // customise!
setcookie( $cookiename, 1, time()-3600, '/' );
- Index
- » Chameleon / ChameleonLite
- » Chameleon
- » Need more than 4 permanent cookies
Board Info
- Board Stats:
- Total Topics:
- 1689
- Total Polls:
- 6
- Total Posts:
- 5942
- Posts this week:
- 2
- User Info:
- Total Users:
- 7633
- Newest User:
- mingle7855
- Members Online:
- 0
- Guests Online:
- 84
- 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