PHP Advanced Programming Study Notes
Design pattern is a set of summary of code Design experiences that are repeatedly used, known to most people, classified and catalogued. The design pattern is used to make code reusable, make it easier for others
PHP Advanced Programming Study Notes
Namespace Overview
PHP versions later than 5.3.0 support namespaces. What is a namespace? In a broad sense, namespace is a way to encapsulate things. This abstract concept can be seen in many places. In PHP, The
Recently, a PHP project used the function of limiting the logon time. For example, if a user logs on to the system 60 minutes later and does not perform any operation, the system automatically exits. I searched for the network to collect the
Sample Code. The substr and iconv_substr, mb_substr functions are used.
Copy codeThe Code is as follows: intercept a Chinese string _ foothome _ www.jb51.net $ Str = 'Welcome to home of 123 ';Echo substr ($ str, 0, 4 );Echo ' ';Echo iconv_substr ($
Download jquery extension wScratchPad. js, the original site page cannot be opened, I am here to provide a wScratchPad-2.1.0.zip
Then (cool), some non-Cool bloggers directly turn to others' articles, and the verification process is saved. It should
Components of MVC:
Model)Represents your data structure. Generally, your model class includes the functions of extracting, inserting, and updating your database data.View)Is the information displayed to the user. A view is usually a
1. library folder
If you want to extend the CI function, place your class library here. Note that this folder is composed of classes. You can see the notes for loading the library!
2. helper folder
If you need to use some functions to complete some
Adhering to the idea of MVC Architecture, All controllers in CI need to load the call through the single point of entry file index. php (default. That is to say, by default, the URLs of all CI development projects are in the following format:
Http: /
1. Download eclipse, find it on the official website, and confirm that there is a java environment in the current system, that is, jdk and jre.
2. After pdt is installed, online installation is used. The update address is included by default. But it
If you want to make a perfect product, you must perform comprehensive inspection and testing on it. There are several types of tests, each of which targets a specific aspect of the application.
This article describes unit testing, database testing,
I am using the widows system. Phpunit of version 3.7.8 is used smoothly. Recently, phpunit has been re-installed and the minimum version has been installed. Many errors will be reported during use. However, you can only downgrade the version to 3.7.8
The implementation result of the following code:
1. the guest with the message displays the welcome word2. General visitor source prompt3. Do not leave a message to the diving Party (refresh more than 7 times and urge the message)4. Push update tips
Php arrays are sorted in Chinese. The file format is generally utf8, but it cannot be sorted directly by asort. It can be gbk or gb2312. This is related to encoding. Gbk and gb2312 are encoded in pinyin.Copy codeThe Code is as follows:Function
The current url is obtained through php. What should I do if I need to extract parameters in the url? This process is actually quite simple. Using the two built-in functions of php can be completed smoothly, namely the parse_url and parse_str
MYSQL Getting started: link to basic transaction processing: MYSQL Getting started: Basic operations http://www.2cto.com/database/201212/ 173868.html MYSQL getting started 2: search using regular expressions http://www.2cto.com/database/201212/ ...
1. common query method a and string: $ arr $ m-& gt; where (& quot; sex0andusername & amp; #39; gege & amp; #39; & quot ;) -& gt; find (); // the string must be enclosed in quotation marks B, array $ data [& amp; #39; sex & amp; #3...
I. common
In PHP, there are a lot of discussions about Sessions. In fact, there are still several functions in PHP4 that we have not noticed at ordinary times. Let me introduce them to you. Session_set_save_handler () is really a good thing. // ***************
// Welcome page (welcome_reserve.php3) Welcome to the Nanjing site ticket booking system & nbsp; welcome to the announcement board: no announcement today online ticket booking order query password modification ticket booking help exit Login & nbsp;
This is a headache. my solution is to use the absolute path and use the $ MAIN_PATH and $ Con_MAINPATH variables to maintain portability. For example, note the difference between URLs and file paths, for example: $ fpfopen ($ MAINPATH/files/a.htm, r)
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