The M method is used to instantiate a basic model class,Difference from method DIs:
1. You do not need to customize model classes to reduce I/O loading and improve performance;2. After instantiation, you can only call methods in the basic Model
The N method of ThinkPHP is a counter method used for core queries and cache statistics. But it can be used for other counting purposes of the application. The usage is relatively simple. The call format is as follows:
N ('count position' [, 'Step
The DESTOON system provides several default home page templates. If you are not satisfied with the templates, you can create them by yourself, next, let's take a look at the key points involved in the company template in the system.
Company
When using the DESTOON system, many people often forget the background management password, or the management password is stolen and needs to be retrieved. At this time, they are often overwhelmed.
In fact, it is very easy to retrieve the password
In the actual use of destoon, we often need to establish some modules that are not available in the system as needed. At this time, we need to copy the existing modules to create new modules based on the existing modules. The specific operation is
When using mkdir to create a folder, we found that this function has two parameters. The second parameter is to specify permissions for the newly created folder.
However, if mkdir ('file address', 0777) is used directly, the permission of the new
PHP summarizes the handling methods for special characters in Form submission, mainly involving htmlspecialchars, addslashes, stripslashes, strip_tags, mysql_real_escape_string, and other functions for joint use.
I. Several PHP functions related to
Copy codeThe Code is as follows:// Heap sorting ApplicationClass heapsort{Var $;Function setarray ($ a) // retrieves an array{$ This-> a = $;}Function runvalue ($ B, $ c) // $ a indicates the array, $ B indicates the sorting heap, and $ c indicates
For example, the following WEB application may display sensitive information to login users:Copy codeThe Code is as follows:$ Authenticated = FALSE;$ Authenticated = check_auth ();If ($ authenticated){Include './sensitive. php ';}?>Because sensitive.
PHP has a configuration option named allow_url_fopen, which is valid by default. It allows you to point to many types of resources and process them like local files. For example, by reading a URL, you can obtain the content of a page (HTML) and view
Install redis on Mac OSFirst, install it. It will be installed under/usr/local/bin by default.Copy codeThe Code is as follows:Cd/tmpWget http://redis.googlecode.com/files/redis-2.6.9.tar.gzTar-zxf redis-2.6.9.tar.gzCd redis-2.6.9MakeSudo make
Since php 4.1.0, the preferred method for getting external variables is to use the hyperglobal variables mentioned below. Prior to this, people were either dependent on register_globals or long pre-defined PHP array ($ HTTP _ * _ VARS ). From PHP 5.0
There are several methods to intercept floating point in php:
1,Float round (float $ val [, int $ precision]) returns the result of rounding val according to the specified precision (number of digits after decimal point. Precision can also be
Find what was found in the mysql help document during mysql_pconnect, and record it here.
The web server uses php to generate a web page in three ways:
I. Use PHP as CGI Wrapper. In this way, each request to reach the web server will cause a php
Principle
Generally, there are two ways to export doc FILES. One is to use com and install it on the server as an extension library of php, and then create a com and call its method. The server that has installed the office can call a name called
Implement functions. Operation items can be deleted separately. Batch items can be deleted, displayed in batches, and hidden (change the status_is value of the AD database );
1. View key points:
Copy codeThe Code is as follows: id?> "> id?>
Copy
13. Construction Overview (buildings. php)
From this article, xnova's research focuses on the process, which is actually a large number of functions. As for the page structure, we will not explain it carefully.
Buildings. the PHP file not only deals
Generally, the general programmers or novice programmers who have problems preventing SQL injection do not filter the data submitted by users, as a result, your database was cracked at the moment of the test. Next we will briefly introduce an SQL
Every xxxAction in ThinkPHP. class. the PHP file represents an application module. Each function in this Action represents an operation. operations can be divided into operations that output to a template and only operations that do not need to be
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