Five Pounds of Flax

Every culture has a burrito.

Using cookies in Ruby on Rails

Wednesday, March 28, 2007posted by Michael Rothwell @ 10:15 PM

The cookies object looks like a hash, but it isn't really.

# this sets a cookie
cookies[:key]="value"

# this does not retrieve a cookie
value = cookies[:key]

# but this does
value = cookies["key"]