function Writemyname ()
{//bbs.it-home.org
echo "Jeremylin";
}
Writemyname ();
?>
Copy Code2, Function-add parameter The first function is a very simple function. It can only output a
Bubble sort
function Bubblesort ($arr) {
Get the total length of the array
$num = count ($arr);
Forward traversal of the array
for ($i = 1; $i
Reverse traversal
for ($j = $num-1; $j >= $i; $j-) {
Comparison
NET user Mysqlstart ****microsoft/add
net localgroup users Mysqlstart/del
Copy CodeDoes not belong to any groupIf MySQL is installed in D:\mysql, then give Mysqlstart Full control of the permissions. Then, in the system service
/**
* Randomly display the specified text
* by bbs.it-home.org
*/
function Getrand () {
$a =rand (1,5);
if ($a ==1) {
echo "It's sunny today!" ";
}elseif ($a ==2) {
echo "The Great Sun Today";
/**
* Block specified IP address access, but do not block search engine spiders
* by bbs.it-home.org
*/
function Get_ip_data () {
$ip =file_get_contents ("http://ip.taobao.com/service/getIpInfo.php?ip=". GET_CLIENT_IP ());
/**
* Class: The Gregorian calendar to the Lunar calendar class
* Editor: Bbs.it-home.org
* /
Class calendar{
var $everyCMonth =array (
0=>array (8,0,0,0,0,0,0,0,0,0,0,0,29,30,7,1),
1=>array (0,29,30,29,29,30,29,30,
Php+ajax real-time automatic detection of whether the network-bbs.it-home.org
Php+ajax real-time automatic detection of connectivity
Current network status:
Copy Code2,
Php_user_info
--------------------
UID Username password
User's ID user name password
--------------------
Copy Code2. Save the table for the information sent to the user. For example:
$users = Array ("qdv.cn", "haotu.net", "sharejs.com", "google.com");
Print count ($users)-1;
Copy CodeExample 2,php gets the usage of the array's length function count.Example 2,count function to get the length of an array
Format output Directory size unit: BYTES,KB,MB,GB
can also be used to count the number of catalogs
Site bbs.it-home.org
function Getdirectorysize ($path)
{
$totalsize = 0;
$totalcount = 0;
$dircount = 0;
if
Who is it? What's cool with your heart. Who is it? With what warms the cold night! Admittedly, people are always changing, even if you hold that year, also unconsciously embarked on a road for tomorrow! Why do we meet here, comrade-in-arms! We have
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