The focus of this paper is on the persistence and denotation of PHP learning and development.
When many people take their three months to learn PHP as a kind of capital everywhere to show off.
When these people show off and switch to other languages.
The following is the original description in php.ini and the default configuration:
; Open_basedir, if set, limits all file operations to the defined directory
; and below. This directive makes more sense if used in a per-directory or
;
1. About capitalization
PHP's built-in functions and structures are case-insensitive.
Such as:
Copy the Code code as follows:
hellophp
Echo ("Hello PHP");ECHO ("Hello PHP");Echo ("Hello PHP");?>
The effect of these three is the same.
Other, user-
A friend to find a job to meet the questions, notes.
It is very likely that I will meet in the future.
Problem: PHP does not use built-in functions for array sorting, possibly descending or ascending
The first method: the legendary bubbling
Compare strlen and Mb_strlen
When the word embox is an English character, the two are the same. Here the main comparison, the Chinese and English mixed in the time, two calculation results. (The encoding method is UTF8 when testing)
Copy the Code
Copy CodeThe code is as follows:
$num = 1220.01;echo Fmoney ($num);//Result: 1,220.21echo Umoney ($num);Results: one thousand and hundred twenty DOLLARS and twenty-one CENTS onlyEcho Umoney ($num, "RMB");Results: one thousand and hundred twenty
Date--Formatting a local time/date
Gmdate--Formats a GMT/UTC date/time and returns Greenwich Mean Time (GMT).
For example, we are now in the time zone is +8, then the server run the following script to return the time should be this:
The current
A good paging algorithm should have the following advantages:
The current page number should be in the middle as far as possible.
If the "Home" and "last" are not available (currently on the first or last page), do not hide the two sets of text so
Example one:
Copy the Code code as follows:
Definition of ClassClass User{attribute, note the scope of public, private, protectedPublic $name = "Hackbaby";constructor functionfunction __construct (){echo "Construct";}Methodfunction Say (){echo "
Are downloading the latest recommended version, originally did not expect to send to the jar, so did not, later summed up to Notepad when found there are quite a lot of problems, so share out, I hope to everyone
Helpful. In doing the experiment, I
Nothing different, the following content is for a Java programmer to master the skills of comparison with PHP! Tell you, they are actually the same, but tools, no high and low points.
But you are not proficient, do not know!
1, syntax: Must be
Smarty Common 20 variable operators * Use syntax: {variable name | operator:}
* Capitalize---initial capital letter
* Count_characters---Count of characters
* Cat---connection string
* Count_paragraphs---Calculation of the number of paragraphs
*
The following regular:
$a = ' 2
tóng
dòng
Canton 3 ';echo preg_replace ('/[^ /', ', $a);
Will prompt:
Warning:preg_replace (): Unknown modifier ' P ' in E:\phpLearn\test.php on line 12
Copy CodeThe code is as follows:
/** Created on 2007-6-8* Programmer:alan, Msn-haowubai@hotmail.com* php100.com Develop a project Php-mysql-apache* Window-preferences-phpeclipse-php-code Templates*/To avoid errors caused by repeating the
1. Confirm that the database service is open
2. Extended Open in PHP.ini configuration
3, check the database related version
(1) Sql2000 at this time to check the PHP directory and Apache bin directory version of the Ntwdblib.dll file is compatible,
__class__ gets the current class name, case sensitive__function__ Current function name, case-sensitive__method__ the current method name, case-sensitiveGet_class (obj);//Gets the class name of the class where the current statement is
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