PHP complete self-study manual

Read(447737) update time(2022-04-15)

Welcome friends to join the ranks of PHP self-study. The PHP language is a general open source scripting language that is easy to get started and easy to use. The "Php Complete Self-Study Manual" can enable learners to have a general understanding of PHP and be able to use this language to perform simple tasks. Website and software development.


PHP is the most popular server-side scripting language for creating dynamic web pages and is open source and free.

PHP stands for Hypertext Preprocessor. PHP is a very popular and widely used open source server-side scripting language for writing dynamically generated web pages. PHP was originally created by Rasmus Lerdorf in 1994. It was originally called Personal Home Page. The

PHP script is executed on the server and the results are sent to the web browser in plain HTML format. PHP can be integrated with many popular databases, including MySQL, PostgreSQL, Oracle, Microsoft SQL Server,Sybaseetc. The current major version of PHP is 7. All code in this tutorial has been tested and verified against the latest version of PHP.

Related resources:

1. PHP 7 topic

2. Exciting PHP7.4

PHP is a very powerful language that is easy to learn and use. Let's try it out and run the first program!

The first PHP program

Instance

<!DOCTYPE html> 
<html> 
<body> 

<?php 
echo "Hello World!"; 
?> 

</body> 
</html>

Run instance»

Click "Run instance " button to view online examples

Isn’t it very simple?

Tips: Our PHP tutorials will help you learn the basics of the PHP scripting language step by step, from basics to advanced topics. If you are a beginner, start with the basics and work your way up, learning a little bit every day. , if you have any questions, please go to the PHP Chinese website PHP Community to ask your questions, and enthusiastic netizens will answer them for you.

What you can do with PHP

PHP can do many things.

  • You can generate pages and files dynamically.

  • You can create, open, read, write and close files on the server.

  • You can collect data from web forms such as user information, email, phone number, etc.

  • You can send emails to users of your website.

  • You can send and receive cookies to track visitors to your website.

  • You can store, delete and modify information in the database.

  • You can restrict unauthorized access to your website.

  • You can encrypt your data for secure transmission over the Internet.

  • There are many other interesting things that can be done with PHP. You'll learn more about them in the following chapters.

Advantages of PHP over Other Languages

If you are familiar with other server-side languages ​​(such as ASP.NET or Java), you may be wondering what makes PHP so special. There are several advantages to choosing PHP.

  • Easy to learn: PHP is easy to learn and use. For beginners who are just starting out in web development, PHP is often considered the first choice of language to learn.

  • Free and open source: PHP is an open source project. It is developed and maintained by a global community of developers, who are free to download and use its source code.

  • Portability: PHP can run on various platforms such as Microsoft Windows, Linux, Mac OS, etc., and it works with almost all servers used today Compatible with, such as Apache, IIS, etc.

  • Fast Performance: Scripts written in PHP generally perform or run faster than scripts written in other scripting languages ​​such as ASP, Ruby, Python, Java, etc. Faster.

  • Vast community: Since PHP is supported by a global community, it is very easy to find PHP-related help or documentation online.

Tips: Did you know that some large websites like Facebook, Youku, Tencent, Sohu and Sina are built with PHP? Most major content management systems (CMS) such as WordPress, discuz, ECSHOP, DreamWeaver CMS, and Empire CMS are also built with PHP.

What This PHP Tutorial Manual Covers

This PHP tutorial series covers all basic programming concepts including data types, operators, creating and using variables, generating output, structuring code to Make decisions in a program or iterate over the same block of code multiple times, create and manipulate strings and arrays, define and call functions, and more.

Once you are comfortable with the basics, you will move to the next level explaining concepts like file systems, sessions and cookies, dates and times, and how to send emails from scripts, process and validate forms, and execute data in PHP filtering and handling errors.

Finally, you will explore some advanced concepts such as classes and objects, parsing JSON data, using regular expressions for pattern matching, exception handling and how to use PHP to manipulate data in a MySQL database and create useful functions, Such as user login system, Ajax search, etc.

Tips: Each chapter in this tutorial contains many practical examples that can be tested using the online editor. These examples will help you understand the concept or topic better. It also contains smart solutions along with helpful tips and important instructions.

Other PHP related learning reference resources

In addition to the knowledge expansion on the right side of this page, the following resources are also selected for everyone

Latest chapter


PHP类型比较 2020-05-26
PHP EOF(heredoc) 2020-05-25
PHP 可用的函数 2019-02-14
PHP PCRE 2019-02-14
PHP RESTful 2016-10-19
PHP 图像处理 2016-10-19
PHP Timezones 2016-10-19
PHP Zip 2016-10-19