Http://www.phpe.net/articles/382.shtml
The MVC pattern is very common in the site architecture. It allows us to create a three-tier application that separates useful layers from the code, helps designers and developers work together and improves
Definition and usage
The PHP extract () function imports variables from the array into the current symbol table.
For each element in the array, the key name is used for the variable name, and the key value is used for the variable value.
The
ASP session is enabled, need to use, directly assigned to the value of it!
However: PHP must first start with session_start () before assigning a value. (except for the php.ini settings changed!) )
In the Expiration time setting, the ASP setting
First open the php.ini file and find the part of the session: (After the semicolon is a comment)
[Session]; Handler used to store/retrieve data.Session.save_handler = files; This is the way the session, the default files can be, the representative
Previously applied to a PHP exported Excel class, there is a piece of code to filter the quotation marks in the string. The use of the Htmlentities () function, and then exported to Excel when another word can not be exported, it feels very strange,
1, Magic constants, there are many, summary of
A identifies the location or name of the script when it is run, etc.
_line_ returns the current line number
_file_ returns the full path and file name of the current script, including an absolute
1. How do I get the content of a Web page address using PHP's environment variables? How do I get an IP address?
echo $_server[' php_self '];echo $_server[' REMOTE_ADDR '];?>
2. Ask for the difference of two dates, for example, 2007-2-5
There are many ways to generate Excel that record a relatively simple one in PHP 5.3.8.
1 function Xlsbof () {2 echo Pack ("Ssssss", 0x809, 0x8, 0x0, 0x10, 0x0, 0x0), 3 return, 4} 5 function xlseof () {6 EC Ho Pack ("ss", 0x0A, 0x00); 7 return;
The parsing of XML is generally the flow way, Dom and XPath mode of three.
PHP is commonly used as a streaming method.
This is the mechanism.
1 Creating a parser using the Xml_parse_create function
$parse = Xml_parser_create ();
2 sets
PHP Array_unique () function
PHP Array function
Definition and usage
The Array_unique () function shifts the duplicate values in the array and returns the result arrays.
When the values of several array elements are equal, only the first
---------------------------------------------------------------------------
A cookie is a mechanism for storing data on a remote browser to track and identify users.PHP sends a cookie in the header of the HTTP protocol, so the Setcookie ()
1. The time format of the day before printing with PHP is 2006-5-10 22:21:21
Solution: Echo Date (' y-n-d h:i:s ', Strtotime ('-1 day '));
Reason:
Format character description return value example
A
Lowercase morning and
PHP optimization is divided into three parts
1, encoding optimization
2,opcode Cache
3, variables and data caching
Coding section
1, the string connection is using "," instead of "." No.
echo "HI". " There "." Good ";
echo "HI", "there",
MATLAB is too big, want to export an executable file, EXE or jar or DLL bar, and then use the program call.
I exported the exe, called with PHP
Install MATLAB and install the VC6 compiler. No use of C + +, under a VC6.0 installed, the system has
AJAX provides users with a more user-friendly and interactive search experience.
AJAX Live Search
In the following AJAX example, we will demonstrate a real-time search.
Real-time search offers many advantages over traditional search:When you
1. First refer to the Js.rar file in the page
2. Using Jquery.ajax ([Options]) Method: Description
Load remote data over HTTP requests.
JQuery underlying AJAX implementations. Easy to use high-level implementation see $.get, $.post and so on. $.
Installation
Window
1. Download Memcache's Windows stable version and unzip it under a disk, for example, in c:\memcached2. Enter the ' c:\memcached\memcached.exe-d install ' installation in the terminal (also known as the cmd Command interface)
Definition and usage
The Realpath () function returns an absolute path.
This function removes all symbolic connections (such as '/./', '/'). /' and extra '/') to return the absolute path name.
If it fails, it returns false. For example, if 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