One, how to define a constant
Keyword: Define syntax define (' Constant name ', ' constant value ')
Two, array
1 Defining an array
The keyword array Syntax array (KEY=>VALUE,KEY2=>VALUE2,KEY3=>VALUE3) key can be an integer or string, value
1. Do not copy variables randomly
Sometimes in order to make the PHP code more neat, some novice PHP (including me) will copy the predefined variables into a shorter name of the variable, in fact, the result is an increase in memory consumption,
Apache is a highly configurable software. It has a lot of features, but each one is expensive. To some extent, tuning Apache is the proper way to allocate resources, and it involves simplifying the configuration to include only the necessary content.
In the current rapid development of the Internet business, new products such as springing up, the old product line new business is also constantly breaking and trying. This puts a higher demand on the rapid development iterations.
First, the basic
First, the basis of logical algebra:
1, the number is represented by binary, and all possible occurrences are only 0 and 12.
2, the basic operation is only "with", "or", "non" three kinds.
With operations defined as: (with & Representations and
1, to many code files said, especially contains a lot of include files (include or require). They need to spend more time and resolution and produce intermediate code.
2, even if the PHP code file does not change, the implementation process will be
Due to the temporary use of foreign space, I published a Blog when I found that time is always wrong. This is a time zone problem, based on my previous experience writing programs. This problem is not difficult to solve, write down my solution for
PHP implementation of statistical user online time method explained:
First introduce the data table structure involved, four fields:
The code is as follows:
Uid
: User ID
session_id
: The system-generated session_id,php after user login is
One of the biggest benefits of using scripting languages is the automatic garbage collection mechanism (which frees up memory) that it has. You do not need to do any free memory processing after using the variables, PHP will help you to complete.Of
sprintfFormats the string.Syntax: string sprintf (string format, mixed [args] ...);return value: StringFunction type: Data processingContent DescriptionThis function is used to format a string. The parameter format is the converted form, starting
PHP class article PHP Object-oriented programming--------------------------------------------------------------------------------the way to develop a large PHP project (ii Translator: Limodou May 16, 2000 author: Luis Argerich Translator: Objects of
Recently a lot of friends are asking me if I can put my that word trojan hidden into HTML or pictures, in fact, a word trojan inserted into the PHP file is already very hidden, if you want to put in HTML files or pictures, then read the test report
A recently written GD gallery is used to generate a class library of column and line graphs, which is a teaching routine.
Class imagereport{
var $X;//Picture size X-axis
var $Y;//Picture size Y-axis
var $R;//Background color R value
var $G;//...
Tree menu has a very wide range of applications in many desktop applications, the main advantage is that the structure is clear, so that users can very clearly know the location of their current. But the application of the tree menu on the Web
I have been running PHP in ISAPI mode (as the mainstream development language now), the biggest drawback is that the stability is not good, when PHP (as the mainstream development language now) error, Apache (Unix platform The most popular Web
PHP defines several constants in advance and provides a mechanism to define them at run time. Constants and variables are basically the same, and the difference is that constants must be defined with the Define function, which, once defined, cannot
How to use PHP (as the current mainstream development language) directly invoke the text file content: First through the file function to open a text file on the server, the returned $myfile will become the handle of the operation, and then through
February 06, 2007
What if an attribute in the Web application takes more than 1 seconds or 2 seconds to complete? Some kind of off-line processing solution is required. Learn several ways to take offline services for long-running jobs in PHP, the
The common use of PHP is: Compile php forget to add an extension, and then want to add extensions, but because the installation of PHP after installing some things such as pear, do not want to remove the directory reload, don't say, PHP really has
Looking at the O ' Reilly Upgrading to PHP (as now mainstream development language) 5, the whim of the MySQL (and PHP collocation of the best combination) to upgrade to 4.1.11, because there is no formal system on the machine, there is no notice of
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