homegrown perl developer usually on linux, but this is on windows box, but not sure that matters....
Can't call method "cookie" on an undefined value at \cgi-bin\article_admin.pl line 11.
error when trying to retrieve cookie value (for a cookie of name 'articles' that i set on a previous page) via CGI in order to test whether user should have access to this page. the relevant code snippet is below. not sure why it would have an undefined value? can anyone help, as i'm undoubtedly just being stupid but am working alone right now and very stuck. thanks.
3 use strict;
5 use CGI;
6 use CGI::Carp qw(fatalsToBrowser);
8 my $query = new CGI;
9 my $cgi;
10 my $cookie_exists ="no";
11 $cookie_exists = $cgi->cookie('articles');