php 环境配置(windows环境)
一、下载apache_2.2.8-win32-x86-no_ssl (1).msi、php-5.2.5-Win32.zip。链接:
二、创建如下目录:注意不要空格
F:\apache
三、安装apache到。安装完成后在浏览器输入127.0.01, 提示it works说明安装成功。注意安装前必须卸载iis
F:\apache\Apache2.2
四、解压php到
F:\apache\php
五、将F:\apache\php\php.ini-dist 重命名为 F:\apache\php\php.ini
六、打开F:\apache\php\php.ini。找到字符串:extension=php_gd2.dll所在行(611行),去掉行首的分号,在接下来的几行里,找到下表中列出的模块所在行,同样去掉前面的分号。
extension=php_gd2.dll
extension=php_mbstring.dll
extension=php_mhash.dll
extension=php_mime_magic.dll
extension=php_ming.dll
extension=php_mysql.dll
七、将F:\apache\php和F:\apache\php\ext加入系统环境变量
八、在F:\apache\Apache2.2\htdocs下创建一个first.php文件。文件内容如下
Hello World'; ?>
九、在浏览器输入http://127.0.0.1/first.php。发现显示的是html源代码。所以打开F:\apache\Apache2.2\conf\httpd.conf.
在125行(找到这两句#LoadModule version_module modules/mod_version.so
#LoadModule vhost_alias_module modules/mod_vhost_alias.so 在这两句先加入下面两句话)
1.
LoadModule php5_module "F:/apache/php/php5apache2_2.dll"
PHPIniDir "F:/apache/php/"
2.在383行添加一行
AddType application/x-httpd-php .php
十、重启php服务器。在浏览器输入http://127.0.0.1/first.php。出现helloWorld。即成功

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

Windows Recovery Environment (WinRE) is an environment used to repair Windows operating system errors. After entering WinRE, you can perform system restore, factory reset, uninstall updates, etc. If you are unable to boot into WinRE, this article will guide you through fixes to resolve the issue. Unable to boot into the Windows Recovery Environment If you cannot boot into the Windows Recovery Environment, use the fixes provided below: Check the status of the Windows Recovery Environment Use other methods to enter the Windows Recovery Environment Did you accidentally delete the Windows Recovery Partition? Perform an in-place upgrade or clean installation of Windows below, we have explained all these fixes in detail. 1] Check Wi

In this article, we will learn about the differences between Python and Anaconda. What is Python? Python is an open source language that places great emphasis on making the code easy to read and understand by indenting lines and providing whitespace. Python's flexibility and ease of use make it ideal for a variety of applications, including but not limited to scientific computing, artificial intelligence, and data science, as well as creating and developing online applications. When Python is tested, it is immediately translated into machine language because it is an interpreted language. Some languages, such as C++, require compilation to be understood. Proficiency in Python is an important advantage because it is very easy to understand, develop, execute and read. This makes Python

PHP integrated environment packages include: 1. PhpStorm, a powerful PHP integrated environment; 2. Eclipse, an open source integrated development environment; 3. Visual Studio Code, a lightweight open source code editor; 4. Sublime Text, a A popular text editor, widely used in various programming languages; 5. NetBeans, an integrated development environment developed by the Apache Software Foundation; 6. Zend Studio, an integrated development environment designed for PHP developers.

Setting environment variables on Windows 11 can help you customize your system, run scripts, and configure applications. In this guide, we'll discuss three methods along with step-by-step instructions so you can configure your system to your liking. There are three types of environment variables System environment variables – Global variables are the lowest priority and are accessible to all users and applications on Windows and are typically used to define system-wide settings. User Environment Variables – Higher priority, these variables only apply to the current user and process running under that account, and are set by the user or application running under that account. Process environment variables – have the highest priority, they are temporary and apply to the current process and its sub-processes, providing the program

Common problems and solutions for Laravel environment configuration file .env When using the Laravel framework to develop projects, the environment configuration file .env is very important. It contains key configuration information of the project, such as database connection information, application keys, etc. However, sometimes there are some common problems when configuring the .env file. This article will introduce these problems and provide solutions, and attach specific code examples for reference. Problem 1: Unable to read the .env file when we have configured the .env file

Go language environment configuration method: 1. Download the go language compiler and double-click to run the installation program; 2. Accept the license agreement and click next; 3. Set the installation directory and click OK; 4. After the installation is completed, change the go installation directory Just add the bin directory to the environment variable.

The difference and connection between the pipenv environment and the virtual environment requires specific code examples. With the increasing popularity of Python, more and more developers are using virtual environments in Python projects to isolate the dependent libraries of different projects. The virtual environment can ensure that the Python libraries and their versions that the project depends on are properly managed to avoid various conflicts and version inconsistencies. However, in the past, using virtual environments required third-party libraries such as virtualenv and virtualenvwrapper. soon

Deleting Conda Environments with One Click: Tips for Quickly Cleaning Up Useless Environments With the rapid development of data science and machine learning, the need to use Python for development and analysis is becoming stronger and stronger. Conda, as a popular Python package manager and environment management tool, is widely used in project development and environment configuration. However, over time, we often leave many useless Conda environments on the computer, which not only wastes disk space, but may also lead to environment clutter and unnecessary trouble. This article will introduce
