Hi, I have tried the following script:
use CGI; my $q = new CGI; print "Content-type: text/html\n\nTestare\n"; $q->redirect("http://localhost/"); Well, if I run this program from a web server, it redirects the page to http://localhost/ but if I run it offline, it just prints: Content-type: text/html testare Why this difference? How can CGI.pm redirect the page if I have printed another HTTP header before printing the redirection header? I have seen that if I do: print "Location: http://localhost/\n\n"; instead of using $q->redirect method, it just prints the both HTTP headers one after another. I have a problem with a script that uses a method for printing a header, method which also sets a session, but then I have put by mistake a redirection header that sets another session, and I couldn't notice that I have used 2 headers, because CGI.pm just do the redirection. Thank you very much. Teddy -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>