Chen Li: Chuanzhi podcasting ancient treasure coin bubble dragon game development lecture 16th: PHP getting started, zhibo bubble dragon game
Chen Li: Chuanzhi podcast ancient treasure coin bubble dragon game development 16th Lecture: PHP getting started
This chapter provides an overview of PHP. Knowledge about dynamic web page technology, PHP introduction, PHP development tools, B/S structure and C/S structure comparison, apache working mechanism analysis, PHP running principle, and PHP environment construction.
I. Introduction to web Development
WEB indicates resources on the Internet host for external access, that is, resources for browser access. Web resources that provide external access on the Internet are divided into static and dynamic resources.
Static web resources (such as html pages): The data on web pages for browsing remains unchanged.
Dynamic web Resources: Data on web pages for browsing is generated by a program. The content displayed when you access a web page at different time points is different.
Static web resource development technologies mainly include Html.
Common Dynamic web Resource Development Technologies: PHP, JSP/Servlet, ASP, asp.net, cgi (Common Gateway Interface), etc.
The focus of our courses is to teach you how to use php Technology to develop dynamic web resources, that is, dynamic web pages.
For example, we need to post, pay online, send text messages, and send emails .... In this way, dynamic web development is required. C-> c ++-> java-> c #.
Ii. Development of Dynamic Web Technology
At the beginning of the network, html (1993) was the most popular at the time. Since html only supports static text and images, it cannot interact with users. To make up for this deficiency, the following web technologies have emerged:
(1) cgi (common gateway interface) Features
A: cgi technology is the most popular dynamic technology in the early days. It is developed more mature and powerful.
B: low efficiency and difficult programming.
C: cgi can be written in different languages (vb, delphi, c/c ++, perl). commonly used languages are c/c ++ and perl.
D: at present, there are few dynamic web pages Using cgi, but there are still some, mainly in linux/unix operating systems.
(2) asp
Asp is the form of html + javascrip (vbscript) + com components. The powerful functions of asp are not limited to using the relevant scripting language but com components, but the development of com components is relatively difficult.
Asp advantages: easy to learn, easy to install and use (windows + iis), higher efficiency than cgi.
Asp deficiency: It is difficult to expand functions because asp functions are extended in com components, while developing com components is more difficult. Security is not high, because asp works with windows and iis, so the security vulnerabilities in windows and iis will affect asp. Poor cross-platform performance makes it difficult to implement enterprise-level functions (such as server clusters and Server Load balancer ).
(3) jsp
Jsp = html + java snippets + jsp syntax + js.
(Mysql-> sun), acquired by oracle2009 [java/solaris/mysql].
Jsp advantages: one-time writing, running everywhere, good cross-platform performance, support for multiple development tools, and powerful Scalability (jsp + javabean.
Lack of jsp: jsp products are highly complex (difficult to get started with jsp than asp). jsp requires a high configuration of machines to run, because jsp runs in class resident memory mode, high efficiency, but more memory is needed.
(4) Php
Official Website: www.php.net
Advantages of Php:
1. good cross-platform performance (Operating System: windwos, linux (redhat, suse, Te), nuix (solaris hpunix aix freebsd), mac ), supports multiple databases (mysql, SQL server, oracle, and DB2 ).
2. high efficiency and good security.
3. Free use (low cost) lamp (linux, apache, mysql, and php kernels ).
4. Open source code. All PHP source code can be obtained.
5. Easy to use. Compared with other languages, PHP is easy to edit and highly practical. It is more suitable for beginners.
6. Object-oriented: php3 does not support object-oriented programming. In php4 and php5, the object-oriented aspects have been greatly improved. Now php can be used to develop large-scale commercial programs.
Disadvantages: the installation is complicated and the configuration is too large. It is too flexible and the interpretation is executed (compared with the compilation and execution), so some errors will be exposed only when they are actually run.
III. Basic concepts of php
Rasmus Lerdorf, father of PHP, was born on February 1, September 22, 1968. To maintain personal web pages, Rasmus Lerdorf has developed some CGI tool programs in C language to replace the previously used Perl programs. Initially these tools were used to show Rasmus Lerdorf's resume and count web traffic. He integrated these programs with some form interpreters called PHP/FI. PHP/FI can be connected to a database to generate a simple dynamic web page program.
Basic concepts of php:
(1) At the beginning of PHP, lerdorf was used to maintain the Personal HomePage "Personal HomePage", and the cgi tool assembly developed in C language was used to replace the perl program.
(2) PHP is short for php Hypertext Preprocessor. PHP is an embedded HTML language. It is a scripting language that executes HTML documents embedded on the server. It is widely used in a style similar to C language.
(4) zend is responsible for the development and commercialization of php.
Php is personla homepage. Currently, zend is responsible for maintenance and commercialization. php is embedded into html code.
The php script runs on the server (for details ).
Php 6.0 is coming soon. It is currently in the snapshot stage. Added functions in php6.0: better support for web2.0, better support for Unicode, more support for Object-Oriented Programming, xml programming, and soap (Simple Object Protocol ).
Iv. php development history
PHP was initially created in 1994 by Rasmus Lerdorf. It was just a simple program written in Perl to count visitors to its own website. Later, I wrote it again in C language, including database access. In 1995, we published the first version of Personal Home Page Tools (PHP Tools). Lerdorf wrote some documents about this program and released PHP1.0.
Software design, program design, PHP tutorial
V. php development tools
IDE (integrated development environment)
① Editplus
② Zend Studio (used more)
③ PHP Coder
④ Phpedit
⑤ Easyecpilse (used more)
6 dw
[Recommended]
Chen Li: Chuanzhi podcast ancient treasure coin bubble dragon game development 16th Lecture: PHP getting started
Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.