Is php written in c?

爱喝马黛茶的安东尼
Release: 2023-02-25 12:50:01
Original
3118 people have browsed it

Is php written in c?

php's interpreter is written in c. The interpreter is equivalent to a weak compiler, but php itself is not based on some underlying language.

PHP is a scripting language executed on the server side, similar to C language, and is a commonly used website programming language. It drives more than 200 million websites around the world, and more than 81.7% of the world's public websites use PHP on the server side. PHP's commonly used data structures are all built-in. It is convenient and simple to use, not complicated at all, and its expression ability is quite flexible.

The core of PHP language is written in C language.

php’s zend engine is entirely implemented in pure C language, and the zend engine is the core part of php. It compiles php code into executable opcode processing and implements corresponding processing methods and basic data. Structure (such as hashtable, oo), memory allocation and management, and providing corresponding API methods for external calls are the core of PHP.

Related recommendations: "php introductory tutorial"

Main features

(1) Open source and free nature

Since the source code of the PHP interpreter is public, websites with higher security factors can change the PHP interpreter themselves. In addition, the use of the PHP runtime environment is also free.

(2) Quickness

PHP is a language that is very easy to learn and use. Its syntax features are similar to C language, but it does not have the complex address operations of C language. Moreover, the concept of object-oriented is added, and it has concise grammatical rules, making it very simple to operate and edit, and very practical.

(3) Extensibility of database connections

PHP can establish connections with many mainstream databases, such as MySQL, ODBC, Oracle, etc. PHP uses different compiled functions to establish connections with these databases For connection purposes, PHPLIB is a commonly used base library provided for general transactions.

(4) Use process-oriented and object-oriented together

In the use of PHP language, you can use process-oriented and object-oriented respectively, and you can mix PHP process-oriented and object-oriented together. , which is something that many other programming languages ​​cannot do.

The above is the detailed content of Is php written in c?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
c php
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!