ID: 5370
Comment by: [EMAIL PROTECTED]
Old Reported By: [EMAIL PROTECTED]
Reported By: [EMAIL PROTECTED]
Status: Closed
Bug Type: Session related
Operating System: Windows 98
PHP Version: 4.0.1pl2
New Comment:

I get these 3 warnings on Windows 98 4.10.2222A, Apache 1.3.14, PHP
4.0.3pl1:

Warning: open(\tmp\sess_906cf0440e666cf0f87ea4bbee139c97, O_RDWR)
failed: m (2) in c:\program files\Apache
Group\Apache\htdocs/session2.php on line 2

Warning: open(\tmp\sess_906cf0440e666cf0f87ea4bbee139c97, O_RDWR)
failed: m (2) in Unknown on line 0

Warning: Failed to write session data (files). Please verify that the
current setting of session.save_path is correct (\tmp) in Unknown on
line 0

The following solved the problem:

Make sure you are editing the php.ini file found in the Php\ directory,
not in the windows\ directory.

Set the session.save_path to an absolute path, relative paths (like
/tmp) don't work.

For example:

session.save_path = C:\Program Files\Apache Group\Apache\htdocs\tmp

I used this prog for testing:

<?php
session_start();
session_register("your_name");
if(!empty($your_name))
{
        echo "I already know your name, $your_name";
}
elseif(empty($your_name)&&!isset($submit))
{
        echo "<form name=myform method=post action=$PHP_SELF>
                <input type=text name=first_name> first name<br>
                <input type=text name=last_name> last name<br>
                <input type=submit name=submit value=submit>
                </form>";
}
elseif(isset($submit)&&empty($your_name))
{
        $your_name=$first_name . " " . $last_name;
        echo "Thank you, $your_name";
}
?>


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

[2000-08-01 22:43:39] [EMAIL PROTECTED]

no feedback, closed

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

[2000-07-05 13:20:13] [EMAIL PROTECTED]

Also, what happens if you set enable_cookies to ON? 
And try also: 
                           printf('<a href="script.php?%s">Link</a>',
session_id());


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

[2000-07-05 13:16:27] [EMAIL PROTECTED]

Does it happen on other win32 platforms too?

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

[2000-07-05 13:15:11] [EMAIL PROTECTED]

Please supply reproducing code.

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

[2000-07-05 13:13:08] [EMAIL PROTECTED]

No error messages.
It shows nothing.

The session file cotains like this:
!foo|

Well, if u put some echos b4 or after the 'echo $foo',
even a break line after it, it shows nothing..like this:
B4 line

After line

BTW, the server platform is Windows 98 SE 4.10.2222.A, PWS 4.0.

More php.ini
register_globals = On
track_vars = On

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

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/?id=5370


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


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to