RE: [PHP] Session var read by form C++ CGI prog ?
| From: | John Bryan | Date: | Tue, 02 Sep 2003 18:38:59 +0000 |
| Subject: | RE: [PHP] Session var read by form C++ CGI prog ? | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-161460@lists.php.net to get a copy of this message | ||
On Tuesday, September 02, 2003, at 01:32PM, Ford, Mike [LSS] <M.Ford@lmu.ac.uk> wrote:
>On 02 September 2003 19:22, Raditha Dissanayake wrote:
>
>> Hi,
>>
>> Had a similar problem when building upload progress bar. Initially i
>> used cookies but that had a few minor hiccups. What you can do is to
>> encode your variables into the query string. This is
>> accessible as part
>> of the env. variables. Since you are familiar with C++ you
>> will get the
>> hang of PHP very quickly.
>>
>> oh and btw the correct way to set a cookie is with
>> session_register(),
>> $_SESSION is used for retrieval.
>
>Er, nope. If you have a version of PHP with the $_SESSION array, then you use it for both
>setting *and* retrieving -- session_register() and friends should *not* be used in this case.
>(Indeed, there are circumstances where the combination of session_register() with $_SESSION gives
>broken behaviour.)
>
Right. I am running PHP 4.3.3. Win32 version to be specific, on Win2k server, with Apache 1.3.26.
I installed PHP to try and do this trick.
JB