help-cgicc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Use cgicc Class to set cookie.


From: Stephen F. Booth
Subject: RE: Use cgicc Class to set cookie.
Date: Mon, 30 Jul 2001 20:05:29 -0400

> I'm pretty new to C++ programming. I have downloaded the cgicc class
> library. I am trying to set cookie using it. The following is the code
> segment where I try to set the cookie:
>
>   cout << HTTPCookie::HTTPCookie("authentication", Value1,"Hello
> World!",
>
> "devel.dhhs.state.nc.us",life,"/",false)
>          << HTTPHTMLHeader() << endl;

I think you need to add another endl before you output the HTTPHTMLHeader,
like

cout << HTTPCookie("foo","bar") << endl << HTTPHTMLHeader();

The cookie doesn't output it automatically because you might want to set
more than one, which you couldn't do if it wrote the \n for you.  This is
probably something that should be documented, provided that this is actually
the problem!

-Stephen




reply via email to

[Prev in Thread] Current Thread [Next in Thread]