Split
(PHP 3, PHP 4)
Split -- use a regular expression to split a string into an array
Description
Array split (string pattern, string [, int limit])
Tip: The preg_split () function uses Perl-Compatible Regular Expression syntax, which is usually a
Run the PHP compilation command:
Sudo./Configure --With-apxs2 =/usr/local/apache2/bin/apxs -- With-MySQLSudo Make
The following error message is generated:
/Usr/local/src/PHP- 5.4 . 3 /EXT/standard/ Info . C: 105 : Ext /Standard/. libs/
PHP Include () and require () are two methods that contain external files. Many beginners may not understand the differences between the two methods. The following summarizes the differences between PHP Include () and require:
1: loading failure
Environment:Operating System: Windows 2003 Server SP2PHP version: php-5.2.6-Win32
1. Download FastCGI for IIS6
Http://www.iis.net/download/fastcgi
After downloading the SDK, double-click it to install it.
After installation, five files are
The unset () function of PHP is used to clear and destroy variables. unused variables can be destroyed using unset. However, in some cases, the memory occupied by destroying variables cannot be reached with unset! Let's first look at an example:
The world is divided into 24 time zones, GMT is a zero time zone, that is, the Greenwich Mean Time. China is located in GMT, eight hours more than GMT. For example, GMT is 09:45:32, and our time is 01:45:32.
The mktime () function of PHP returns
PHP is basically an array language. There are often a lot of array loop operations, mainly in two ways, one is foreach, the other is while, in the end, which is good or bad is always controversial, although I have been aware of this problem for a
For PHP + MySQL + Apache packaged with rpm, the GD library is installed by default.
If you want to compile and install these files, you must install the GD library by yourself.
I compile and install (Source code) Apache + PHP. The GD library
Introduction: this is the core technology of the PHP Forum-detailed page for hierarchical storage, display, and return. It introduces PHP, related knowledge, skills, experience, and some PHP source code.
Class = 'pingjiaf' frameborder = '0' src = '
Introduction: This is a detailed page for configuring the PHP environment in Windows 7. It introduces PHP, related knowledge, skills, experience, and some PHP source code.
Class = 'pingjiaf' frameborder = '0' src = 'HTTP: //
The substr () function built in PHP cannot be used to truncate Chinese characters, and garbled characters in both Chinese and English may occur. The following two solutions are provided.
1. gb2312 encoding truncation,
1 Function Msubstr ( $
PHP string operation function set String sorting: Chop (), ltrim (), and trim () The first step to sort strings is to clear unnecessary spaces in strings. By default, the characters to be removed are linefeeds and carriage returns (N and R),
Exception ):Exception Handling is used to change the normal process of the script when a specified error (exception) occurs.
When an exception is triggered, it usually occurs:
The current Code status is saved.
Code execution is switched to a
Require () and include () have many similarities and differences. Understanding their differences is very important, otherwise it is easy to make mistakes.
I will describe these two statements together, So readers can learn more. . Require ()
I. single quotation marks and double quotation marks are used in PHP's data storage process. That is, when storing data in the database, you must note that single and double quotation marks are escaped;
Let's talk about several PHP functions:
1.
1. Getting Started
In short, regular expressions are a powerful tool for pattern matching and replacement. We can find regular expressions in almost all UNIX-based tools, such as the VI Editor, Perl or PHP scripting language, and awk or SED Shell
Prerequisites
Determine whether the remote URL is valid. The remote URL includes remote images, webpages, videos, and other elements.Solution: Use PHP
Use the file_get_contents function. However, if the URL cannot be accessed, the program will be
For ($ I = 10; $ I> 0; $ I --){Echo $ I;Flush ();Sleep (1 );}?>
According to the PHP Manual
This function sends all the output of the program so far to the user's browser.
The above code should output $ I every second. But not necessarily in
Form: http://blog.ixpub.net/html/92/15070492-280599.html
In general, the phpinfo () page can be displayed. Let's start with the problem that occurs after the page is displayed.PHP problems are displayed on the phpinfo () page.
First, check
Introduction
Part 2 describes how to use Sajax, PHP, and JavaScript to develop basic albums. In the process of building a history stack for an application, we will rely on the Client technology and directly combine it with Part 1 of the Code. This
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