Copy CodeThe code is as follows:
$file = fopen (' text.csv ', ' R ');
while ($data = Fgetcsv ($file)) {//reads a row of CSV each timePrint_r ($data); This is an array, to get every data, access the array subscript can$goods _list[] =
How can I tell if a Web request is an AJAX request or a normal request in PHP? You can do this by passing parameters, such as using the following URL request:
/path/to/pkphp.com/script.php?ajax
use the following method in the PHP script to
Now everyone advocates that XML is the best friend of Web developers, with the help of XML, which can easily format and display data from almost any data source. However, for dynamic content, well-formed data is far from ideal. Most Web developers
PHP learning is still going on, but in some large PHP exchange forum encountered some friends on the most basic database concept is not clear, then produced the idea of writing this article!
(i) Concept
A database is a collection of information in
There is a lot of data about PHP cache classes on the Web, but this class should be one of the things I've seen that meets the needs of functionality, but is incredibly concise. Don't say much nonsense, just look at the code!
Instructions for use:
Constant detection uses defined, and defining constants is define. Note the constants to be detected need to use quotation marks (single and double), such as:
The code is as follows
if (defined (' Const_name ')) {Do something}
Variable detection
Definition and usageThe Number_format () function formats numbers by using thousands of groupings.
GrammarNumber_format (Number,decimals,decimalpoint,separator)
Parameter descriptionNumber required. The number to format. If no other parameters are
Needless to say, the last article has a core concept is give action do something!
In this article I use the code to explain the meaning of this concept, first look at my post.class.php. This file is our data layer processing class.
Simply
Recently to a friend to modify the site, to help guests of the small to find some of the site's image is a PNG format, and the picture file is very large, almost all over 200KB, and the same pixel jpg pictures will be much smaller, so in the
Hide the Apache and PHP version information, Web server avoid some unnecessary trouble, can put Apache and PHP version information does not display
Hide Apache Version Information
/etc/apache2/apache2.conf or/etc/httpd/conf/httpd.conf
Servertokens
0. It is quicker to use single quotes instead of double quotes to contain strings. Because PHP will search for variables in a string surrounded by double quotes, single quotes will not, note: only echo can do this, it is a string can be used as a
Reason:
If the Ipv6,curl is turned on by default, the IPV6 will be resolved first, and if the corresponding domain name is not IPv6, it will wait for IPV6 DNS resolution to fail to find IPv4 in accordance with the previous normal process. In the
We often see the statistical code of many Web sites are displayed in the form of JS calls, let's look at how that example.
$countfile = "Num.txt";The definition counter writes the file to the current directory under Count.txt, and then we should
In PHP to record the execution time of the code in the page we only use the Microtime function to generate the time, and then subtract the start and end time at the end to resolve.
Core code
The code is as follows
$t 1
Off-topic (can skip)
I believe this article has let everyone wait too long, not my trick, hang everyone's appetite, but write an article really need to spend too much time. Perhaps an article, you spend 3-5 minutes to read, school will master, and
Public platform Development public platform development Model Enterprise public platform tree hole Micro bo tree cave Renren Tree Cave
Author:Square Double Studio
Address: http://www.cnblogs.com/txw1958/p/weixin-65-weibo-treehole.html
Fairy
In many projects will ask users to upload things these, since the contact with jquery and Ajax no matter what to do, first of all will think of this, I this person? is to pay more attention to customer experience, this time I am responsible for the
Local server, domain name http://d.com, root path D:\phpnow\vhosts\d.com.yii, relative root directory owning file/x.php code requeir_once/a/a.php, and/a/ a.php and requeir_once/a/b/b.php ./x.php
$_server["Http_host"]: "d.com"//HOST of the
Template Management, template selection, select BlueSky, select OK, template Management, set up templates, product categories under category (click on the item in the front of the category, and then select "Main area of the middle", the serial
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