This article describes the PHP regular does not contain a string of the wording, the regular expression does not contain the specified string example, the need for a friend reference.
In PHP programming, the common function of matching
cd/etc/yum.repos.d/
CP Centos-base.repo Centos-base.repo.bak
Copy Code1.2 Replace the source with VI open Centos-base.repo, and empty the contents, then copy the contents below and save.
Yum-y Update
The Linux compiler installs the PHP libevent extension method, implements the high Performance Network service in the PHP programming, needs the support of the Libevent extension Library, this article installs the Libevent Extension Library by
How do you use regular expressions in PHP programming? PHP Regular expression usage, need to refer to a friend.
Contents of this section:PHP Regular ExpressionsA regular expression is a powerful tool that can be used for pattern matching
This paper introduces the method of CodeIgniter to realize the intelligent cropping picture, the picture is cropped and not distorted, as far as possible to retain the meaning of the theme of the picture, the need to refer to friends.
Add picture watermark to background image (location random), JPEG for background image, GIF for watermark picture format
function watermark ($filename, $water) {
Get the width and height of the background picture
List ($b _w, $b _h) =
AddHandle Fcgid-script. fcgi
Fcgidconnecttimeout 20
# to get around upload errors if uploading images increase the maxrequestlen size to 15MB
Fcgidmaxrequestlen 15728640
Copy CodeIf it is a php+apache Windows
Recently in the work need to convert BMP images to JPG pictures, but helpless is the network can find the BMP to GD class or function more or less have some problems. Most of them in the processing of 16-bit BMP picture is either full black powder,
There's nothing special about enclosing the database connection and the text cache in a class.
Class db{
protected $_connect;
protected $_db = Array ();
protected $_cache = Array ();
Public function __construct
Start and end IP addresses for a network segmentFor example: Network segment (192168.1.5/24), whose subnet mask is divided according to 24:11111111.11111111.11111111.00000000 (255.255.255.0)Description: The IP address is 32bits,24 in the division of
This service is a flexible multi-threaded call to curl.This is different from the sample provided in PHP manual http://us2.php.net/manual/zh/function.curl-multi-select.php, and the code execution is much more efficient.Two files in the department,
# TAR-ZXF (fill in the Download Curl package name here)
#./configure–prefix=/usr/local/curl
# make, make install
copy code When you install PHP, just turn on the switch –with-curl=/usr/local/curl. PHP requires the directory
!--? php
function get Imageinfo ($img) {//$img is an absolute path to an image file, for example, D:\iamge\jn0-541.gif
$img _info=getimagesize ($img);
switch ($img _info[2]) {
case1:
$imgtype
/*Website Language English Solution--by changing the buffer to achieveFunction: According to the cookie to determine the user's choice of language, the default is Chinese (do not replace), when the user selects English in the page, then through the
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