Forum: Ruby on Rails Save a cookie with unescaped content

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Abff9b659ff79293aaae22b8e996a57f?d=identicon&s=25 Alisson Sales (Guest)
on 2009-01-31 12:50
(Received via mailing list)
Hi, i'm trying to save a cookie with some especial characters like
this 'diasnd190823===??//<<asddas'

But rails escape this characters.

Anybody knows how can i do that?

I've tried this ways without success:

1:
cookies['mycookie'] = {:value => 'diasnd190823===??//<<asddas'}

2:
mycookie = CGI::Cookie::new('name' => 'mycookie', 'value' =>
'diasnd190823===??//<<asddas')
respose.headers["cookie"] << mycookie

Thanks,
Alisson Sales
This topic is locked and can not be replied to.