A classmate asked a question:
Copy the Code code as follows:
for ($i = ' A '; $i echo $i;}
What is the output?
The output is:
Abcdefghijklmnopqrstuvwxyzaaabacadaeafagahaiajakalamanaoapaqaras .....
Why?
In fact, it is very simple, the PHP manual
The principle of the function is very simple, the main is to use a recursive call.
Copy the Code code as follows:
function File_list ($path) {if ($handle = Opendir ($path)) {while (false!== ($file = Readdir ($handle))) {if ($file! = "." && $file!
Save the image to the database PHP code
Copy the Code code as follows:
If ($Picture! = "None") {$PSize = FileSize ($Picture);$mysqlPicture = Addslashes (Fread (fopen ($Picture, "R"), $PSize));Mysql_connect ($host, $username, $password) or Die
Copy the Code code as follows:
#*******************************************#作用: Page no action, auto expiration function#参数: $onlinetime The last time the current page was used#参数: $interval page Time-out#返回: None#*******************************
Write process
Copy the Code code as follows:
Get the path of the configuration file$fname = jpath_configuration. DS. ' configuration.php ';Clear Cache$cache = Jfactory::getcache ();$cache->clean ();Update the credentials with the new
1.PDO Introduction
PDO (PHP Data Object) is something added to PHP 5, which is a significant feature of PHP 5, since php4/php3 before PHP 5 is a bunch of database extensions to connect and process with each database, what Php_mysql.dll, Php_
The functions that are discarded in php5.3 are:
Ereg ()///Mb_ereg instead, or Preg_match instead, but matching rules need to be used/included.
Eregi ();//preg_match instead, add I after the rule, such as: Preg_match ("/^ (Style|style_) (. *) */i",
Later on the fire, in the virtual machine installed WIN2003 a test, loading MSSQL module is no problem, but with mssql_connect ("localhost", "sa", ""), but how also not connected to the database, and later on the Internet to check a lot of
1) Use the tag to set the page encoding
The purpose of this tag is to declare the client's browser with what character set encoding to display the page, XXX can be GB2312, GBK, UTF-8 (unlike MySQL, MySQL is UTF8) and so on. As a result, most pages
The Repeater control does not have built-in rendering capabilities, which means that the user must provide a layout for the Repeater control by creating a template. When the page runs, the Repeater control renders an item for each record, in turn,
We're going to use the membership table structure
Copy the Code code as follows:
CREATE table if not EXISTS ' net_111cnnet ' (' id ' int (one) not NULL auto_increment,' username ' varchar (+) default NULL,' Add_time ' int (one) default NULL,' Email
First go to the PHP site to download the installation files used. Depending on the needs of your choice, I chose to install this version: Php-5.3.2-win32-vc9-x86.msi. You can download the selection as needed.
Then you can download the installation
1. Simple anti-theft chain
Copy the Code code as follows:
$ADMIN [Defaulturl] = "http://jb51.net/404.htm";//Address returned by hotlinking$okaysites = Array ("http://jb51.net/", "http://www.jb51.net"); White List$ADMIN [Url_1] =
http://code.google.com/apis/ajaxsearch/documentation/#fonje
Copy the Code code as follows:
//This example request includes a optional API key which you'll need to //remove or replace with your own Key. //Read More on why it's useful to has an API
PHP has $_get,$_post, but no $_put, so if you need to use it, then you have to simulate it yourself:
Copy the Code code as follows:
$_put = Array ();if (' PUT ' = = $_server[' Request_method ')} {Parse_str (file_get_contents (' Php://input '),
Xdebug Installation
When downloading the xdebug extension, note that the Xdebug version corresponds to the PHP version, otherwise there will be unnecessary trouble!
I am using PHP5.2.5, download the Xdebug file named: Php_xdebug-2.0.3-5.2.5.dll, put
The source code is opened, the string is used in line wrapping method for "name:{$name}\naddress:{$adress}\ncity:{$city}\ncountry:{$country}\n ..."
Since "\ n" does not serve the purpose of the line, modified to "\ r \ n" Look.
Modify = "Submit ="
The contents of the sql.php file are as follows:
Copy the Code code as follows:
System ("Mysql-uroot-pmypassword Database print "SQL OK";?>
Where root represents the database user name, MyPassword represents the root password, database
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