in reply to Re: Re: Not able to set and retrieve cookie
in thread Not able to set and retrieve cookie

If you are using CGI (which you rightly should be as you are), you shouldn't manually output your headers. Calling $query->header(); will do it for you, and $query->header( -cookie => $newcookie ); will print out the Set-cookie header, as well as the Content-type header.

Replies are listed 'Best First'.
Re: Re^3: Not able to set and retrieve cookie
by bradcathey (Prior) on Apr 29, 2004 at 02:16 UTC
    Sorry, I didn't quite follow you, but I wish I did. If you, whoever you are, get a chance, can you expound a bit? I can't tell if I was doing it right or if you were suggesting another way. Thanks.

    —Brad
    "A little yeast leavens the whole dough."

      He was telling you that when you do print $query->header(-cookie=>$newcookie); Thats already going to print out the content-type so you don't need the following line at all. print "Content-type: text/html\n\n";


      ___________
      Eric Hodges