in reply to Re: Displaying another web page
in thread Displaying another web page

Hi Linda,
Thnk you for fast response.
Im using CGI::Session module.
I have written print $cgi->redirect(-uri=>"http://localhost/reports.pl",-cookie=>$cookie)
$cookie points to teh session variable which im initializing in the beginning of the program.
now, as soon as user presses "login" button, my perl script has to show "reports.pl" page and should display the values stored in session variable.
this is what i need actually.
But, it is not going to reports.pl page.It remains in the same page.
Pls help me Linda.

Replies are listed 'Best First'.
Re: Re: Displaying another web page
by eric256 (Parson) on Apr 20, 2004 at 16:54 UTC
    When printing a redirect you need to make sure that is the only thing you are printing. Don't print a header before that.

    ___________
    Eric Hodges
      hi Eric,
      I removed the header which im printing before $cgi->redirect.<br? eventhough it is not going to the specified URL.
      Instead printing a message like
      Status: 301 Set-Cookie: CGISESSID=5ad97ae74acf2fd202ce63a7021cd576; path=/ Date: Wed, 21 Apr 2004 04:38:51 GMT location: http://localhost/reports.pl
      pls help me Eric.
      Thankx in advance.