We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Plugin: Cookie Plus

Development and Programming

Luke Hardiman's avatar
Luke Hardiman
109 posts
about 16 years ago
Luke Hardiman's avatar Luke Hardiman

@goodcompany, you may find you have a line in your config.php file that is preventing you from editing the cookie prefix in the Control Panel.

       
birdie's avatar
birdie
68 posts
about 16 years ago
birdie's avatar birdie

Hi, I think I might be missing something obvious here, but is there any reason this wouldn’t work?

I have set a cookie on a previous page, with the name “redirect” and the value containing the current page url. This is for an “Age Verification” script. When the user hits a page it checks for the “Age” cookie, if it is not present the user is redirected to the “agechecker.php” form.

I’d like to pull the value of the redirect cookie, and use it in the action of the form, so the user gets returned to their previous entry page:

{exp:cookie_plus:get name="redirect" parse="inward"}
<form class="applyForm" id="lda-form" action="{cookie}">
{/exp:cookie_plus:get}

When I use the code above the result is a blank action, so either it’s not reading the cookie, or not displaying the value:

<form class="applyForm" id="lda-form" action="">

Thanks for your help!

       
rewdy's avatar
rewdy
12 posts
15 years ago
rewdy's avatar rewdy

Thanks! I love this plug in! Really just helped me a lot.

       
Jim Pannell's avatar
Jim Pannell
187 posts
15 years ago
Jim Pannell's avatar Jim Pannell

Hi Laisvunas

Bit of a long shot this, but is it possible to use your plugin to somehow write multiple cookies with the entry_id for all the pages that a (non logged in) person might visit on a site, and then display a list of their ‘recently viewed pages’?

       
Nathan Pitman's avatar
Nathan Pitman
531 posts
15 years ago
Nathan Pitman's avatar Nathan Pitman

We have a ‘recently viewed entries’ module that might help you out here… It’s not on GitHub yet but I’ll try and get it wrapped up tonight and post bak here with the URL. 😊

       
Jim Pannell's avatar
Jim Pannell
187 posts
15 years ago
Jim Pannell's avatar Jim Pannell

That sounds fantastic Nathan! One question though - will it work for users that aren’t logged in?

       
Nathan Pitman's avatar
Nathan Pitman
531 posts
15 years ago
Nathan Pitman's avatar Nathan Pitman

Yes. 😊

       
Jim Pannell's avatar
Jim Pannell
187 posts
15 years ago
Jim Pannell's avatar Jim Pannell

Woohoo!! Can’t wait! 😊

       
Nathan Pitman's avatar
Nathan Pitman
531 posts
15 years ago
Nathan Pitman's avatar Nathan Pitman

So as to not hijack this thread any further, here’s a new topic for the recently viewed entries module: http://ellislab.com/forums/viewthread/148743/

       
Jonathan Schofield's avatar
Jonathan Schofield
175 posts
15 years ago
Jonathan Schofield's avatar Jonathan Schofield

Great plugin this, thanks.

Works very nicely with segment variables. 😊

       
meerestier's avatar
meerestier
17 posts
15 years ago
meerestier's avatar meerestier

Is there a EE 2.0 Version for the cookies plus plugin?

       
Laisvunas's avatar
Laisvunas
879 posts
15 years ago
Laisvunas's avatar Laisvunas
Is there a EE 2.0 Version for the cookies plus plugin?

Not as yet.

       
Studio Hert's avatar
Studio Hert
36 posts
15 years ago
Studio Hert's avatar Studio Hert

Hi

Is it also possible to use multiple cookies in an entries tag? I wanted to use cookies to give some extra parameters, since dynamic parameters don’t work with pagination.

I want something like:

{exp:weblog:entries weblog="wl_agenda"
            pagination="both"
            show_future_entries="yes"
            orderby="entry_date|title"
            search:ag_search="{cookievalue1}"
            limit="{cookievalue2}
            sort="asc|asc"}

(Yes, I know there’s a thread on the forum about manually setting POST parameters, but that had some strange effects, especially with start_on and stop_before.)

       
Laisvunas's avatar
Laisvunas
879 posts
15 years ago
Laisvunas's avatar Laisvunas

Hi,

Is it also possible to use multiple cookies in an entries tag?

No, this is not possible using this plugin.

       
Matt Weinberg's avatar
Matt Weinberg
489 posts
15 years ago
Matt Weinberg's avatar Matt Weinberg

You can probably do it with an embedded template. Use the cookie values as embed:vars to the embedded template, and then put the weblog:entries tag in there.

       
First 2 3 4 5

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.