The solution to the problem that php does not have a php.ini file: first create a new PHP document and view the output information in the browser; then find the specific path of [php.ini] and open the cmd window; finally enter [php - i | findstr php.ini].
Solution to the problem that php does not have a php.ini file:
1. Create a new PHP document. The purpose is to detect the environment configuration of PHP.
#2. Save the above content and view the output information in the browser.
#3. The above information is the configuration information of PHP. Look for: Loaded Configuration File on this page. The specific path of php.ini is in the red box.
4. Open the CMD window and enter: php -i | findstr php.ini.
#5. After pressing the Enter key to execute, you can also get the path to the php.ini configuration file.
Related learning recommendations: php programming (video)
The above is the detailed content of What should I do if php does not have a php.ini file?. For more information, please follow other related articles on the PHP Chinese website!