Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Setting a COOKIE in redirect object



Actually, the cookie isn't getting seen at all on the receiving end.  That was an old cookie I was seeing.

Jeff

On Jul 31, 2007, at 11:43 AM, Jeff Schmitz wrote:

Thanks! that worked.  Nasty bug in WO.

Now, I have a cookie question that seems to cause weird behavior too.

I'm setting a cookie with the following code:

 WOCookie atpCookie = new WOCookie("ATP_PID_1004", encryptedValue);
    redirect.setUrl(url);
  response.addCookie(atpCookie);
 redirect.appendToResponse(response, context());
    return redirect;

When I retrieve and print out cookies on the invoked page using this code:

System.out.println("login cookie values: " + this.request().cookieValues().toString());

I get:

login cookie values: {ATP_PID_null = ("b3c6bd86effa3de9b4c6c410c22f98"); }


Why is the name of my cookie getting changed from ATP_PID_1004 to ATP_PID_null?

Thanks,
Jeff

On Jul 31, 2007, at 10:49 AM, Zak Burke wrote:

Jeff Schmitz wrote on 7/31/07 11:28 AM:
However, when I pick up the parameters on the other side, there is a stray "&" being added before the NICK parameter. 

[...]

When I print the dictionary out it shows:
login Hyperlink values: {amp;NICK = ("FireBreathers"); USER = ("1004"); amp;wosid = ("a1snzyY9gzOgLCObCkS5kg"); }


Actually, it looks like a stray "amp;" rather than "&" which makes me think WO is double-encoding the ampersands.
See this recent post:


and this older one:


zak.

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/email@hidden

This email sent to email@hidden

References: 
 >takeValueFromRequest phase (From: Lachlan Deck <email@hidden>)
 >Setting a parameter in redirect URL (From: Jeff Schmitz <email@hidden>)
 >Re: Setting a parameter in redirect URL (From: Zak Burke <email@hidden>)
 >Re: Setting a COOKIE in redirect object (From: Jeff Schmitz <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.