in reply to Small problem with handling cookies
Please, show more code. Also take a look to WWW::Mechanize.