1. Introduction and function of regular expressions.
01. What is a regular expression?
Regular Expressions (English: Regular Expression, regex, or RegExp, abbreviated as RE), also translated as regular representations, general representations, in
Curl Implement get Submit data
The code is as follows
Copy Code
Initializes a CURL object$curl = Curl_init ();Set the URL you want to crawlcurl_setopt ($curl, Curlopt_url, ' http://www.111cn.net ');Set header, last
file System-based page Counter example
The code is as follows
Copy Code
? Php$countfile = "Num.txt";Defines that the file written by the counter is count.txt under the current directory, and then we should test
The code is as follows
Copy Code
if (!isset ($_get[absolutepage])) {$absolutepage =1;//Current Page}if ($_get[absolutepage]==0) {$absolutepage = 1;}else {$absolutepage =$_get[absolutepage];$absolutepage =intval
If it is just a normal file download, php is not necessary at all, you can use it. But sometimes, to keep the file confidential, you can only download it to some people. Obviously, you cannot tell others the chaincode, in this case, no
The code is as follows:Copy code The code is as follows:Copy code Ajax POST Real POST Person info will be listed here. Php codeHeader ('content-Type: text/html; charset = utf-8 ;');Echo "POST data:". implode ('', file ('php: // input '))
The principle isIf the data passes the preceding two verifications, the data is valid and valid. At this time, we concatenate the submitted data into a string and use MD5 encryption to obtain an MD5 value. Then we put this value on the client
The code is as follows:Copy code // Function name: CheckWebAddr ($ C_weburl)// Usage: Determine whether the website is valid// Parameter: $ C_weburl (URL to be detected)// Return value: Boolean// Standby Note: None// Configure //------------------
The code is as follows:Copy code $ File = "C:/Users/Public/Music/Sample Music/kalimbaloud "; If (! File_exists ($ file )){Exit ('media file does not exist .');} // Create a Windows Media Player interface$ Player = new COM ("WMPlayer. OCX ");$
insert title here user name: Password: duplicate password: Name: Gender: male Female Age: Mobile Phone: communication address: Email Address: user Photo: date of birth: verification code:
PHP is quickly promoted with ease of use, but it is not easy to say that it can be used. In fact, many programmers use it to easily establish a WEB application system, but how many people have carefully considered their code, whether it is easy to
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