Php perfect non-redundant code traversal folder parameter 20 returned directory file 1 returned directory file + Directory 2 returned Directory all files + empty directory (for some 2 types of development, -_-B) 3. return to all files in the
PHP and other class functions 1. same class knowledge as Java 1. class and object public, private, constructor, thisClassperson {public $ length; // member variable _ construct () {// Constructor} publicfunction PHP and so on
Class functions
I.
Php uses zip & nbsp; in PHP, you can use PHP's own ZIP function to package and decompress some files. this is more convenient than other languages. the method is summarized as follows: 1. open PHP. extended extension in INI, enabled (this function
Java programmers to learn php-16exception processing and java style consistent thrownewException ('exception', 33); // than java has an error_codetry {java programmers to learn php-16 exception processing
Same style as java
Throw new Exception ('
Java programmers learn php-13. value passing is the same as passing a reference to php and Java. when calling a function, the basic data type is passed with a value, and the object is passed with a reference. However, php can also pass a reference
Php Cache ob series function analysis (reprinted) reprinted original address: bytes ;? Phpfor ($ I = 10; $ I & gt; 0; $ I --) {& nbsp; & nbs php Cache ob series function analysis (reproduced)
Reprinted original
Java programmers learn php-14. object-oriented similarities: 1. also class + Method 2. multi-inheritance is not allowed. you can also use interfaces to implement multi-inheritance. there are also abstract classes 5. there are also static methods 6.
PHP regularly executes ignore_user_abort (); // closes the browser, and the PHP script can still be executed. set_time_limit (0); // you can use set_time_limit (0) to run the program without restrictions $ interval = 60*30; // run do {PHP scheduled
Java programmers learn php-12. variable scope 1. php has a more "file" scope than java (the official name is "global scope", which is valid in the current php file ), that is, the scope of the variables written in the PHP file but independent of any
Java programmers learn php-2. non-Boolean type can be forcibly used as a Boolean type as long as the data is not 0, it can be used as true; otherwise, it is used as false. If ("abc") {& nbsp; echo "abc"; // willprint "abc"} I java programmers learn
Thinkphp generates static file configuration $ this-& gt; buildHtml ('hello', 'user/', 'index'); is this produced under the user directory? Hello.shtml also has cache configuration. By the way, the production cache is configured. if it is not
Install and configure the PHP development environment in Windows 7. Apache installation version description: openssl indicates that the openssl module is included. you can configure the SSL security link for Apache by using openssl, that is, using
Java programmers learn php-4.gettype ()/settype () 1. gettype () get the data type & nbsp; for example, gettype (345); // return "integer" & nbsp; gettype (java programmers learn php-4. gettype ()/settype ()
1. gettype () get the data type
For
Php saves remote images to a local Device & lt ;? Phpheader ('content-Type: image/jpg '); echofile_get_contents ("http://www.baidu.com/img php save remote image to local
First: exact
': "False ";
Method 2: extract images from articles
PHP Chinese garbled processing 1. the file storage format is ANSI encoding 2. add & lt; metahttp-equiv = "Content-Type" content = "text/HTML; charset = gb2312"/& gt; 3 to the html page. heade php Chinese garbled characters are added at the top of
PHP5VC9, VC6, ThreadSafe, NonThreadSafe versions of the difference PHP official website (http://windows.php.net/download/) 5.3 a total of four versions, differences between versions of VC9x86NonThreadSafe, VC9x86ThreadSafe, VC6x86No PHP5 VC9, VC6,
The IP address recorded in the text database. if the IP address already exists, it will not be added. if the IP address does not exist, it will be recorded in the text data. there will be a total of debugging errors. Document 1: & lt ;? Php & nbsp; $
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.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service