1, if you can define the method of the class as static, as far as possible to define static, it will increase the speed of nearly 4 times times.
2, $row [' ID '] speed is $row[id] 7 times times.
3, ECHO is faster than print, and uses Echo's
0. It is quicker to use single quotes instead of double quotes to contain strings. Because PHP will search for variables in a string surrounded by double quotes, single quotes will not, note: only echo can do this, it is a string can be used as a
0. It is quicker to use single quotes instead of double quotes to contain strings. Because PHP searches for variables in a string enclosed in double quotes, single quotes are not, note: only echo can do this, it is a "function" that can take
Last month I specifically introduced the PHP introductory tutorial on the basic syntax of PHP introductory learning, mainly introduced several commonly used PHP tags, the composition of PHP statements, PHP comments, and so on, today's PHP
0. It is quicker to use single quotes instead of double quotes to contain strings. Because PHP searches for variables in a string enclosed in double quotes, single quotes are not, note: only echo can do this, it is a "function" that can take
PHP Kernel Exploration: namespacesNamespaces are a special type of scopeThank you for reference or the original www.php-internal.com server June spent a total of 81.974 MS 3 database queries, and strive to provide you with this page. Try reading
1. It is quicker to use single quotes instead of double quotes to contain strings. Because PHP will search for variables in a string surrounded by double quotes, single quotes will not, note: only echo can do this, it is a string can be used as a
PHPerror_reporting(E_all);/*PHP 5.3 Introduces lazy static bindings*//*php5.4 introduced trait, used to implement multilayer inheritance trait hello{} trait world{} class myhelloworld{use Hello,world;}*//*php4 times PHP is not a destructor-capable*//
When assigning a value to a variable, PHP allocates a zval to store the value, while the ZVAL structure does not have a variable name.After 5.3, the release improved the garbage collection mechanismIf you find that the refcount in a zval container
1. If a method is static, make a static declaration of it. The rate can be increased to 4 times times.2.echo is faster than print.3. Use Echo's multiple parameters (meaning: a comma instead of a period) instead of a string connection.4. Determine
[PHP]
; PHP is still an evolving tool, and its functionality is constantly being pruned
; and PHP.ini's setting changes can reflect quite a change,
; Before using the new PHP version, it would be helpful to look at the php.ini.
;;;;;;;;;;;;;;;;;;;
;
1, if you can define the method of the class as static, as far as possible to define static, it will increase the speed of nearly 4 times times.2, $row [' ID '] speed is $row[id] 7 times times.3, ECHO is faster than print, and uses Echo's multiple
To assign a value to a variable's pass address
In PHP 3, variables are always assigned values. PHP 4 provides another way to assign a value to a variable: to send an address assignment. Using a pass address assignment, simply appends a (&) symbol
Magic variable
PHP provides a large number of predefined constants to any script it runs.
However, many constants are defined by different extensions, and are only available when the extensions are loaded, either dynamically or at compile time.
Think that the collation of the more detailed, the pro, quickly collect it!
PHP System class functions
assert function: Check if assertion declaration is wrongextension_loaded function: Check that the PHP extension is loadedGet_cfg_var function:
It is quicker to use single quotes instead of double quotes to contain strings. Because PHP searches for variables in a string enclosed in double quotes, single quotes are not, note: only echo can do this, it is a "function" that can take multiple
PHP Multiple optimization methodsOne of the PHP optimization configurations lets the forum speed faster PHP acceleration set PHP Acceleration: Zend Optimizer Optimize PHP program
Zend Optimizer V2.5.7 for WindowsSoftware language: EnglishOperating
1. If a method can be static, make a static declaration on it. The rate can be raised to 4 times times.
2.echo is faster than print.
3. Use Echo's multiple parameters (meaning to use a comma instead of a period) instead of a string connection.
4.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.