Graphic explanation PHP environment building tutorial,
Preface
PHP was developed by Rasmus Lerdorf in 1995. Up to now, PHP has been washing for decades and has become one of the world's most popular scripting languages. Because PHP5 is an object-oriented, fully cross-platform new Web development language, it is very practical from both the developer perspective and the economic perspective. PHP is simple in structure and easy to get started. Many functions can be implemented with only one function. Many organizations have successively introduced new technologies such as IDE tools for php development and Zend search engines.
What is PHP
PHP (Hypertext Preprocessor, Hyper Text Preprocessor) is a server, cross-platform, HTML embedded scripting language. Its unique syntax combines the features of C language, Java language, and Perl language, it is a widely used open-source multi-purpose scripting language, especially suitable for Web development.
PHP is the B/S (Browser/Server, Browser/Server) architecture and is a three-tier structure. After the server is started, you can access the server without using the client software. This not only maintains a graphical user interface, but also greatly reduces the amount of application maintenance.
Advantages of PHP
PHP originated from free software and open source code. Using PHP for Web application development has the following advantages.
High Security:PHP is an open-source software. Everyone can see the source code of all PHP. The compilation of program code and Apache makes its security settings more flexible. PHP has a recognized security performance.
Cross-platform features:PHP supports almost all operating system platforms and multiple Web servers such as Apache and IIS.
Supports a wide range of databases:Attackers can manipulate a variety of mainstream and non-mainstream databases, such as MySQL, Access, SQL Server, Oracle, and DB2. PHP and MySQL are currently the best combination, and their combinations can run across platforms.
Easy to learn:PHP is embedded in the HTML language and mainly used as the script language. It has a wide range of built-in functions, simple syntax, and easy writing, making it easy for readers to learn and master.
Fast execution speed:It consumes less system resources and executes code quickly.
Free:In the popular enterprise application LAMP platform, Linux, Apache, MySQL, and PHP are all free software. This open-source free framework can save a lot of money for website operators.
Templated:Separates the program logic from the user interface.
Supports object-oriented and process:Supports object-oriented and process development styles and is backward compatible.
Embedded Zend Acceleration Engine, stable and fast performance.
New Features of PHP5
· Constructor and constructor.
· Object reference.
· Object cloning.
· Private, public, and protected modes of objects.
· Interface.
· Abstract class.
· _ Call.
· _ Set and _ get.
· Static members.
Click here to view the PHP Chinese manual
Use the AppServ package in Windows
A combination package is to package Apache, PHP, MySQL, and other server software and tools after installation. Developers only need to extract the configured kit to the local hard disk, without further configuration. The combination package enables quick setup of the PHP development environment. For programmers who have just started learning PHP, we suggest using this method to build a PHP development environment. Although the package combination is much less flexible, it is easy to install, fast, and stable to run. Therefore, it is suitable for beginners.
There are many popular combination packages on the Internet. Three types of combination packages are recommended: EasyPHP, AppServ, and XAMPP. For beginners, EasyPHP or AppServ is recommended, while XAMPP is complicated.
Click to download the AppServ package:
For example:
Construction of the comprehensive installer package
1. Double-click the AppServ file to open the startup page, for example:
2. Click Next to open the AppServ installation protocol page, as shown in:
3. Click the I Agree button to open the page as shown in. On this page, you can set the AppServ installation path (the default installation path is c: \ AppServ). After the AppServ installation is complete, apache, MySQL, and PHP are all stored in this directory as subdirectories:
4. Click the Next button to open the page shown in. On this page, you can select the programs and components to be installed (the default status is full ):
5. Click the Next button to open the page as shown in. This page mainly sets the Apache Port Number:
The setting of the Apache port number is crucial. It is directly related to whether the Apache server can be started successfully. If port 80 in the local machine is occupied by IIS or thunder, the server configuration cannot be completed if port 80 is still used here. You can solve this problem by modifying the port number or modifying the IIS or thunder port number.
6. Click Next to open the page, as shown in. This page mainly sets the logon password and Character Set of the root user of the MySQL database. Here, set the character set
"GB2312 Simplified Chinese" indicates that the character set of the MySQL database will be in Simplified Chinese format:
7. Click the Install button to start installation. For example:
8. UI for installation:
After AppServ is installed, the entire directory is installed in the "c: AppServ" path by default. This directory contains several subdirectories:
Open your browser and enter "http: // localhost/[the port number you set. If it is 80, you do not need to enter]" in the address bar. If it is enabled, AppServ is successfully installed:
With the development of PHP, a large number of excellent development tools have emerged. Finding a suitable tool not only accelerates the learning progress, but also promptly discovers problems in the future development process, reducing detours. The development tool we choose is Dreamweaver. For details about how to create a project, see online documents.
The above is all the content of this article. I hope it will be helpful for your learning and support for helping customers.