OK fixed it, it had to do with a serialized array, which also had to
be urlencoded, why I'm not sure, but that fixed it. I guess WAMP
doesn't give the cookie some extra treatment the server did.

On May 26, 2:10 pm, CheshirePuss <[email protected]> wrote:
> Another difference I found was that on the local server, when I check
> cookies in firefox, A cookie is added every time i visit the page, and
> when I add a vote cookie (when it works), I see as the cookie name
> CakeCookie[votes], whereas when I execute the same code on the
> production server, I get no new cookie every page refresh (which might
> be good), and as cookiename when I vote (which doesn't work) I get
> CAKEPHP. Is it a domain-question? Because I haven't set this variable.
>
> On May 25, 6:16 pm, CheshirePuss <[email protected]> wrote:
>
> > Ok thanx, that didn't work though.
> > BTW is it necessary to set all those things for a cookie, it doesn't
> > just work out of the box?
>
> > On May 25, 4:57 pm, ar2oor <[email protected]> wrote:
>
> > > check yours cookie configuration
>
> > > $this->Cookie->path = '/';
> > > $this->Cookie->domain = 'domain.com';
>
> > > On Mon, May 25, 2009 at 7:07 AM, CheshirePuss (via Nabble) <
> > > [email protected]<ml-user%[email protected]>
>
> > > > wrote:
>
> > > > I'm trying to implement a voting system, and I want to use a cookie to
> > > > store the items that the current user already voted for, thus going
> > > > against multiple voting.
>
> > > > function vote($dir,$id,$type)
> > > > {
> > > > $votes = $this->Cookie->read('votes');
> > > > /*process data, adding or subtracting id's and stuff from the array
> > > > $votes*/
> > > > $this->Cookie->write('votes', $votes);
> > > > }
>
> > > > in appcontroller:
> > > > var $components = array('Cookie');
>
> > > > and this works when I use it on my local WAMP testing server.
> > > > But when I upload it to m production server, $votes stays empty, even
> > > > though, when I check my cookies, a cookie was made for every item
> > > > voted for.
> > > > I have no idea what causes this, does anyone else?
>
> > > > ------------------------------
> > > >  View message @
> > > >http://n2.nabble.com/cookie-stays-empty-on-production-server-tp296803...
> > > > To start a new topic under CakePHP, email
> > > > [email protected]<ml-node%[email protected]>
> > > > To unsubscribe from CakePHP, click here< (link removed) =>.
>
> > > --
> > > View this message in 
> > > context:http://n2.nabble.com/cookie-stays-empty-on-production-server-tp296803...
> > > Sent from the CakePHP mailing list archive at Nabble.com.
>
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to