Ovid has asked for the wisdom of the Perl Monks concerning the following question:
Apache seems to handle this just fine. Unfortunately, here's what I'm getting from IIS 4.0:#!C:\perl\bin\perl.exe use CGI; my $cgi = CGI->new; my @cookieOut; push @cookieOut, ($cgi->cookie( -name => 'id', -value => "something", -expires => '+7d', -path => '/')); print $cgi->redirect( -cookie => \@cookieOut, -location => 'productCategory.cgi' );
Notice that the Client-Peer line has an extra newline, effectively ending the headers and killing any chance of a redirect. Also, I notice that it says HTTP/0.9. If I add print $cgi->header; before the redirect (I was just testing, I know it breaks it), all of a sudden, IIS reports HTTP/1.0 -- still not to HTTP/1.1, but I have no frickin' idea what's up with that.HTTP/0.9 200 OK Client-Date: Fri, 22 Dec 2000 21:02:08 GMT Client-Peer: 192.168.1.65:80 Status: 302 Moved Set-Cookie: id=something; path=/; expires=Fri, 29-Dec-2000 21:59:38 GM +T Date: Fri, 22 Dec 2000 21:59:38 GMT Location: productCategory.cgi
I need to know what's up with the extra newline in that header. Again, it works fine for Apache. Is there something in my code I can change to get this to work with IIS, or is this just a server issue?
Cheers,
Ovid
Join the Perlmonks Setiathome Group or just click on the the link and check out our stats.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: IIS and Apache
by chromatic (Archbishop) on Dec 23, 2000 at 05:13 UTC | |
|
Re: IIS and Apache
by merlyn (Sage) on Dec 23, 2000 at 04:59 UTC | |
|
Re: IIS and Apache
by extremely (Priest) on Dec 23, 2000 at 16:03 UTC | |
|
(Ovid - response to IIS responses) Re: IIS and Apache
by Ovid (Cardinal) on Dec 24, 2000 at 00:00 UTC | |
by extremely (Priest) on Dec 24, 2000 at 15:08 UTC | |
by mwp (Hermit) on Dec 24, 2000 at 05:15 UTC | |
|
Re: IIS and Apache
by dws (Chancellor) on Dec 24, 2000 at 04:03 UTC | |
|
(Ovid - IIS is pitiful) Re: IIS and Apache
by Ovid (Cardinal) on Dec 27, 2000 at 02:23 UTC |