PHP cookies (source code)
/** Cookies class: save, read, update, and clear cookies. You can set the prefix. Force timeout. Data can be strings, arrays, and objects.
* Date: 2013-12-22
* Author: fdipzone
Code for reading files by row (implemented in php and c)
/**
* Reading files by row
* @ Param string $ filename
* @ Site bbs.it-home.org
*/
Function readFileByLine ($ filename)
{
$
How to install xdebug and pearphpunit in php
Zend_extension = "F: \ php_dev \ php \ ext \ php_xdebug-2.2.1-5.4-vc9.dll"
[Xdebug]
Xdebug. auto_trace = on
Xdebug. collect_params = on
Xdebug.
PHP sample code for exporting a style Excel file
/**
* Export an excel file with a style
* Edit: bbs.it-home.org
*/
Include 'writer. php ';
/***** Prepare the exported data ****/
$
Php implementation code for getting repeated data in an array
Function FetchRepeatMemberInArray ($ array ){
// Obtain the array for removing duplicate data
$ Unique_arr = array_unique ($ array );
//
Php replaces small functions of html content
/**
* Replacing html content
* By bbs.it-home.org
*/
Function htmlsp ($)
{
If (strpos ($ a, '
{
Echo $;
} Else
{
PHP, MySql, and jQuery implement the "top" and "Step On" voting functions
Create table if not exists 'votes '(
'Id' int (10) not null AUTO_INCREMENT,
'Lik' int (10) not null default '0 ',
'Unlik' int (10) not
Simple example of removing 3D php arrays
// Create an empty array.
$ Tmp_array = array ();
$ New_array = array ();
// 1. loop all rows. ($ val is a row)
Foreach ($ my_array as $ k => $ val )
Two example of removing repeated data from the array using php
/**
* Remove repeated data from the array
* By bbs.it-home.org
**/
$ Input = array ("a" => "green", "", "red", "B" => "green",
Php detects sample code for uploading excel files
/**
* Detect upload file type
* Check the excel file type of the uploaded file
* @ Param array $ file
* @ Return bool $ flag
* @ Site
The phpdate function is used to format the output time in a specified range.
/**
* The date function is used to format the time in the specified output range.
* By bbs.it-home.org
*/
$ Stand = "201
Php code for deleting image files while deleting records
/**
* When deleting a record, the image file will be deleted together.
* By bbs.it-home.org
*/
$ Cn = mysql_connect ('127. 0.0.1 ', 'root',
Introduction to php-fpm configuration
This article introduces the configuration method of php-fpm in the php environment, and describes the configuration options and methods of php-fpm in detail. if you need them, refer to them.This section
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