From: sas sas Date: 2006-04-07T15:15:27+09:00 Subject: Re: accessing session with session.each Well, I'm even more impressed Just had to class CGI::Session extend Forwardable def_delegators :data, :each, :each_pair, :length, :size def data unless @data @data = @dbman.restore end @data end end and that's it saludos Sas PS: theres a typo in http://www.ruby-doc.org/stdlib/libdoc/forwardable/rdoc/classes/Forwardable.html where it says class RecordCollection extends Forwardable def_delegator :@records, :[], :record_number end it should be "extend Forwardable" and not "extends Forwardable" I'll send a mail to suggestions@ruby-doc.org Saludos Sas -- Posted via http://www.ruby-forum.com/.