Oh yes, good one - and I was going to add, why are you using CGI but not using it?
#!/usr/bin/perl -w
use CGI ;
my $q = new CGI;
my $co_userid = $q->cookie(-name=>'user',
-value=>'dummy',
-domain=> '.jplan.com',
-path=> '/cgi-bin/') ;
my $co_password = $q->cookie(-name=>'password',
-value=>'hispassword',
-domain=> '.jplan.com',
-path=> '/cgi-bin/');
print $q->header(-cookie=>[$co_userid,$co_password]),
$q->start_html({-title => 'CTB Discussion Index',
-style => {'src'=>'../../ctb/css/header.c
+ss'},
-bgcolor => '#FFFFFF',
-topmargin => 2,
-marginheight => 2,
-leftmargin => 2,
-marginwidth => 2),
$q->p('Cookie is set'),
$q->br,
$q->end_html;
As for the password, I'd set a session ID instead, that expires after a certain length of time (store it in a text file or DB somewhere for later checking).
cLive ;-) | [reply] [d/l] |