Php prompts that memory location access is invalid solution Summary

Source: Internet
Author: User

This article collects a Summary of the solutions to the error prompt "invalid memory location access" when using php. If you need it, please refer to it.

The newly configured PHP environment or configuration changes have just been made, such as the newly loaded DLL extension and webpage access, may cause "invalid memory location access ." . The main reason is that the DLL extension fails to load.

We need to find the DLL file to load. The troubleshooting method is as follows:

In php. ini

The Code is as follows: Copy code

Display_startup_errors = Off
Change

Display_startup_errors = On.

When you access the php page, a php error dialog box will pop up on the server. You can clearly see which dll file fails to be loaded, and sometimes multiple dll files fail to be loaded, you need to annotate php with a semicolon (;) first. ini prompts that the dll will be accessed again and again.

If I open

The Code is as follows: Copy code
Display_startup_errors = On

Appears

Warning Cannot load module 'sqlite 'because required module 'pdo' is no loaded


The solution is also simple. Because the php_sqlite.dll file is not loaded when it is loaded, the system prompts that the access to the memory location is invalid when running the phpinfo () function. Find the php. ini configuration file and remove it.

The Code is as follows: Copy code
"; Extension = php_pdo.dll" front semicolon, extension = php_sqlite.dll


After the problematic dll is commented out with a semicolon (;), php can run normally.

If the above method cannot be solved, refer to the following method

Open the php Directory and start debugging ...... It took some time to find the root cause

If you encounter this problem, you can try the following solutions:

Open the php installation directory and edit the php. ini file.

Search for the following fields

The Code is as follows: Copy code

Extension = php_exif.dll

Add a; semicolon

As follows:

The Code is as follows: Copy code

; Extension = php_exif.dll

Save and restart iis and access the PHP file again to see if the file is opened and whether the access to the memory location is invalid.

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.