in reply to CGI::Session::MySQL
That code is working in may application.#!/usr/bin/perl -W # # use CGI::Session; use CGI::Session::MySQL; use CGI qw(:standard); use CGI::Carp qw(fatalsToBrowser); use DBI; use strict; my $config = { DSN => 'DBI:mysql:dc151fc_session', MySQLunm => 'xxxx', MySQLpwd => 'xxxx', cartURL => 'http://xxxx.com/cgi-bin/cart.pl?cmd +='}; my $DEBUG = 1; my $cgi; my $session; my $cart; $cgi = new CGI; my $dbh = &createDBconnection( $config->{DSN}, $config->{MySQLunm}, $c +onfig->{MySQLpwd} ); $session = new CGI::Session("driver:MySQL", $cgi, {Handle=>$dbh}); my $cookie = $cgi->cookie(-name=>'CGISESSID', -value=>$session->id, -e +xpires=>'+1d'); print $cgi->header(-cookie=>$cookie);
....john
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: CGI::Session::MySQL
by Cody Pendant (Prior) on Aug 07, 2003 at 03:35 UTC | |
by jdtoronto (Prior) on Aug 07, 2003 at 04:30 UTC | |
by Cody Pendant (Prior) on Aug 07, 2003 at 10:26 UTC |