CentOS5.5 install LAMP (php environment) using yum
Cd/etc/yum. repos. d/
Cp CentOS-Base.repo CentOS-Base.repo.bak
1.2 replace the source open the CentOS-Base.repo with vi, clear the content, copy the following
Phpmemcached data cache entry example
Class mycache
{
Private $ cache;
Function _ construct ()
{
$ This-> cache = new memcache ();
// You can replace localhost by memcached server ip
PHP two-dimensional array sorting customization function
A user-defined function for sorting php two-dimensional arrays. let's take a look at it.
The code is as follows:
$ V) {$ keysvalue [$ k] = $ v [$ keys];} if ($
What should I do if an error is reported when uploading large files in phpfastcgi mode?
Addhandle fcgid-script. fcgi
Fcgidconnecttimeout 20
# To get around upload errors when uploading
Differences between php static methods and static variables
This article introduces the differences between static and static variables in php classes. if a non-static method is used, $ this is not used in the change method, that is,
Php5.3 does not support session_register (). What should I do if this function is enabled?
// Fix for removed Session functions
Function fix_session_register (){
Function session_register (){
$ Args =
Php user-defined function to convert the U.S. time to Beijing time
Function datezhuanhuan ($ dateparams)
{
$ Ccc = strtotime ($ dateparams );
$ Date = date ('Y-m-D ');
$ Bjtime = date ('Y-m-D', $ ccc );
PHP simulated logon to QQ mailbox to obtain the QQ friends list
/**
* @ File class. qqhttp. php
* QQ mail login and retrieval class
* @ Author wc
* @ Site bbs.it-home.org
Php generates Chinese garbled QR codes. what should I do? Solution
$ UrlToEncode = "http://gz.altmi.com ";
GenerateQRfromGoogle ($ urlToEncode );
Function generateQRfromGoogle ($ chlorophyll, $ widhtHeight = '00000
Precautions for job hopping for programmers
1. the jump is much faster than the jump.Many people think that today's programmers are very cool and it will not take long for them to jump. However, have you ever thought about the cause. If you
Php Chinese characters and hexadecimal encoding conversion methods
// Convert Chinese characters to hexadecimal encoding
Function hexencode ($ s ){
Return preg_replace ('/(.) /es ', "str_pad (dechex (ord ('
Code for displaying records by page in PHP + MySQL
$ Pagesize = 10; // set the number of records displayed on each page
$ Conn = mysql_connect ("localhost", "root", ""); // connect to the database
$ Rs =
Use PHP and cURL to get URLs
Http://css.dzone.com/articles/retrieving-urls-parallel-curl
Class Footo_Content_Retrieve_HTTP_CURLParallel
{
/**
* Fetch a collection of URLs in parallell using cURL. The results are
PHP database operation base class (Singleton mode)
Database operation base classes written by yourself, including the most basic CURD operations, which can be integrated into the framework.
// Configuration file
$ Db =
Obtain the visitor's operating system
Obtain the visitor's operating system
Function osinfo (){
$ OS = "";
$ Agent = $ GLOBALS ["HTTP_USER_AGENT"];
If (eregi ('win', $ Agent) & strpos ($ Agent, '95') {//
QuentinZervaas & amp; apos; sDBO
Quentin Zervaas, author of Web 2.0 development practices, is a simple PHP Data Access Object.
/**
* DatabaseObject
*
* Abstract class used to easily manipulate data in a
Example of smarty paging
@ Session_start ();
Require_once ("smarty. php"); // load the smarty template class
Require_once ("adodb/adodb. inc. php"); // load the adodb database
// Connect to 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