Hello all,
I have created a tasklist for my staff at work.
I wrote and tested it on my PC at home running
Linux 2.4.20 with Apache 2.0.45 and Perl 5.8.0.
The user first hits a login page where they select
their shift and enter their name,
that information is set in a cookie for later use.
The actual page with the tasks will check for the cookie
and if it does not find it, the user is redirected to the
login page.
Now, it worked just fine at home, but when I put it on our
server at work, Solaris server on and UltraSparc 5 running
SunOS 5.8 Apache 1.3.26 and Perl 5.8.3 it will create the cookie but will fail to recognize it's existance.
I have tried it at home using Apache 1.3.27
and that works as well.
Here is the code from the login.cgi file:
#!/usr/bin/perl -w
use strict;
use warnings;
use CGI qwstandard);
use CGI::Carp qw(warningsToBrowser fatalsToBrowser);
my $q = new CGI;
my $username = param ('username');
my $shift = param ('shift');
# Register the cookies
my $cookie1 = $q->cookie(-name=>'TASKLIST_LOGIN',
-value=>"$username:$shift",
-expires=>'+12h');
print $q->header(-cookie=>[$cookie1]);
And here is the relevant part of the tasks script:
#!/usr/bin/perl -w
use strict;
use CGI qwstandard);
use CGI::Carp qw(warningsToBrowser fatalsToBrowser);
my $q = new CGI;
# Check user is logged in and get user name and shift
if(defined $q->cookie('TASKLIST_LOGIN')) {
my $cookie = $q->cookie('TASKLIST_LOGIN');
(my $username, my $SHIFT) = split(/:/, $cookie);
We are running XP with IE 6 here at work and you can
go into Tools->Internet Options->Settings->View Files
and see and read the cookie so I know it's getting created.
Anyone have any ideas?
I am lost..
I have created a tasklist for my staff at work.
I wrote and tested it on my PC at home running
Linux 2.4.20 with Apache 2.0.45 and Perl 5.8.0.
The user first hits a login page where they select
their shift and enter their name,
that information is set in a cookie for later use.
The actual page with the tasks will check for the cookie
and if it does not find it, the user is redirected to the
login page.
Now, it worked just fine at home, but when I put it on our
server at work, Solaris server on and UltraSparc 5 running
SunOS 5.8 Apache 1.3.26 and Perl 5.8.3 it will create the cookie but will fail to recognize it's existance.
I have tried it at home using Apache 1.3.27
and that works as well.
Here is the code from the login.cgi file:
#!/usr/bin/perl -w
use strict;
use warnings;
use CGI qwstandard);
use CGI::Carp qw(warningsToBrowser fatalsToBrowser);
my $q = new CGI;
my $username = param ('username');
my $shift = param ('shift');
# Register the cookies
my $cookie1 = $q->cookie(-name=>'TASKLIST_LOGIN',
-value=>"$username:$shift",
-expires=>'+12h');
print $q->header(-cookie=>[$cookie1]);
And here is the relevant part of the tasks script:
#!/usr/bin/perl -w
use strict;
use CGI qwstandard);
use CGI::Carp qw(warningsToBrowser fatalsToBrowser);
my $q = new CGI;
# Check user is logged in and get user name and shift
if(defined $q->cookie('TASKLIST_LOGIN')) {
my $cookie = $q->cookie('TASKLIST_LOGIN');
(my $username, my $SHIFT) = split(/:/, $cookie);
We are running XP with IE 6 here at work and you can
go into Tools->Internet Options->Settings->View Files
and see and read the cookie so I know it's getting created.
Anyone have any ideas?
I am lost..