ID:               22013
 Updated by:       [EMAIL PROTECTED]
 Reported By:      [EMAIL PROTECTED]
-Status:           Open
+Status:           Feedback
 Bug Type:         Session related
 Operating System: Windows
 PHP Version:      4.3.0
 New Comment:

Not enough information was provided for us to be able
to handle this bug. Please re-read the instructions at
http://bugs.php.net/how-to-report.php

If you can provide more information, feel free to add it
to this bug and change the status back to "Open".

Thank you for your interest in PHP.


your script contains errors: $this is not an object.

Add:
error_reporting(E_ALL);

in line 1 to see if there's anything else reported.



Previous Comments:
------------------------------------------------------------------------

[2003-02-02 12:35:33] [EMAIL PROTECTED]

Today I upgraded from PHP 4.2.2 to PHP 4.3.  I am using Apache 2.0.43
on Windows with PHP CGI.

After doing this upgrade, setcookie() stopped working for me using
Mozilla 1.3a though it continued to work using IE.  setcookie() was
working for me with both browsers before the upgrade.

Here is a script that illustrates the bug.

<?php

define('ID', 'id');
define('USERNAME', 'username');

// save the login information into the cookie which will expire in 30
// days
$expirationTime = time()+60*60*24*30;
$domain = $_SERVER['HTTP_HOST'];
$success = true;
if (!setCookie(ID, $this->id, $expirationTime, '/', $domain, 0)) {
  $success = false;
}
if (!setCookie(USERNAME, $this->username, $expirationTime, '/',
$domain, 0)) {
  $success = false;
}

if ($success) {
  print "setCookie's succeeded";
} else {
  print "setCookie's failed";
}

?>


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=22013&edit=1

Reply via email to