php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #6005 setcookie always returns "1"
Submitted: 2000-08-07 09:07 UTC Modified: 2000-08-07 12:58 UTC
From: phil at BuxTech dot Com Assigned:
Status: Closed Package: Misbehaving function
PHP Version: 4.0.1pl2 OS: Solaris 7 & 8
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: phil at BuxTech dot Com
New email:
PHP Version: OS:

 

 [2000-08-07 09:07 UTC] phil at BuxTech dot Com
It would seem that the php4 function setcookie() always return a value of 1.  In php3, one could check the return value from setcookie to determine in the clients' browser was accepting cookies ...

I can find nothing in the documentation relating to this change.

We are using Apache 1.3.12 with php4 statically linked in (as we've been unable to use php4 as a DSO under Solaris because of runtime library path problems [a different issue]).  I'd be happy to supply a list of modules compiled in or my php.ini file but I've duplicated this problem with no ini file and a vanilla compilation.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-08-07 12:58 UTC] rasmus@php.net
You are wrong.  PHP 3 could not determine this as there is no way to know whether the client accepted the cookie or not.
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Sun Oct 11 10:00:01 2026 UTC