CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Beginner:
Can't read a cookie

 



douge
Deleted

May 24, 2000, 3:13 PM

Post #1 of 1 (736 views)
Can't read a cookie Can't Post

I'm using the following code to read a cookie and redirect based on if it exists or not.
_______________________________

use CGI;

$co = new CGI;

%greetings = $co->cookie('greetings');

if ($co->param('name')) {
$greetings{'name'} = $co->param('name')
}

if ($co->param('birthday')) {
$greetings{'birthday'} = $co->param('birthday')
}

if(exists($greetings{'name'})) {

$url = 'http://fixed40/test/macomprod.html';
print "Location: $url\n\n";

} else {

$url = 'http://fixed40/test/magetinfo.html';
print "Location: $url\n\n";

}

It works on my personal web server but when I try it on the NT IIS server it's a no go. Anybody have any ideas? Thanks in advance.

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives