Windows Apache + PHP session lost resolution process full record, Apache full record _php tutorial

Source: Internet
Author: User
Tags learn php session id php session

Windows Apache + PHP session lost resolution process full record, Apache full record


Today's job is to migrate a PHP site to a new server.

Create a Windows Server 2008 virtual machine and stop the net stop HTTP service on it (avoid scrambling for 80 ports), install the configuration Apache + PHP, migrate the site to the new server, the site is open normally, Apache + PHP is running normally, connect MySQL Server Normal, everything is fine, Ben thought about half an hour to finish the work, followed by the nightmare began.

The site uses single sign-on, and the logon process contains JavaScript asynchronous operations that contain SOAP calls to Web Service. Login but jump back to the login page without any error, consider the following possible:

1, is the account abnormal? In other system tests, the account status is normal.

2. Is JavaScript asynchronous operation failed? Use the IE Developer tool to track the JavaScript return value and return the value to normal.

3. Is the Web service call failing? Tracing the return value of the Web service with fiddler indicates that a local login has been completed with successful validation.

Repeatedly tracking debugging, only to begin to suspect that the site session is missing:

1, JavaScript asynchronous operation set session failed, is it because of synchronous access and asynchronous access to the session ID is different caused? This happens asynchronously in Flash, does JavaScript also? The session ID value for output synchronous access and asynchronous access is the same.

2, Build 2 PHP test page, set the session in one page, but not read on another page. Check php.ini related settings, looks normal, see Session.save_path = "c:/php/tmp" path, but really no session related files, set up the TMP directory is not.

The result is ironic, there is no TMP directory, PHP cannot write to the session file, the natural session is lost. Why there is no TMP directory, because there is no in the installation package ... Me for 3 hours.

The above mentioned is the whole content of this article, I hope to be able to learn PHP to help you.

http://www.bkjia.com/PHPjc/980226.html www.bkjia.com true http://www.bkjia.com/PHPjc/980226.html techarticle Windows Apache + PHP session lost resolution process full record, Apache full record of today's work is to migrate a PHP site to the new server. Create a Windows Server 2008 virtual machine, and ...

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.