I am trying to write a cookie : request.cookies[''ad_w1''] = {:value => "#{advertising.id}", :expires => Time.now.utc+1.year} or any other test cookies[:user_id] = { :value => ''123'', :expires => Time.now + 1.hour} but I continously get an error : TypeError: can''t modify frozen hash something gets wrong but where ? thanks for your lights .... ------ note : discovered that .... Rails breaks the hash implementation that cookies appear, on the surface, to support. For whatever reason, symbol access of values doesn''t work but string access does. Also, for whatever reason, the nil? method will not work but the empty? method does. Hopefully this saves somebody some frustration! request.cookies[''note''].value unless request.cookies[''note''].empty? -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---