A function that can convert Chinese characters to pinyin

A function that can convert Chinese characters to pinyin $d =array ( Array ("A",-20319), Array ("AI",-20317), Array ("an",-20304), Array ("Ang",-20295), Array ("AO",-20292), Array ("BA",-20283),

PHP5 exception handling, error throwing and callback functions, etc.

Error_reporting (E_all&~e_notice); In addition to e_notice other exceptions are triggered (the result of the E_all&~e_notice binary operation is that the value of the e_notice corresponding bit is set to 0) Try-catch cannot take effect within the

Chan Cheng Loan----Only for programmer's bank loans

Chan Cheng Loan---programmer "money" "process" worry-freeLoan RequirementsAge: 22-55 years oldInterest rate: Minimum 7.8 pct (borrowing 10000, interest 78 yuan/month)Loan limit: up to 1000000.00Duration: 3 Months-10Loan Time: The fastest

A case of socket programming in PHP

Error_reporting (E_all); Set_time_limit (0); echo "TCP/IP Connection\ n "; $port = 1935; $ip = "127.0.0.1"; /* +------------------------------- * @socket connect the whole process +-----------------

PHP foreach Reverse Sequence output example

PHP foreach positive sequence reverse outputExample: Positive order foreach ($files as $file _num = $file) { if (Is_file ($directory. $file)) { $file = Iconv ("gb2312", "UTF-8", $file); or

PHP gets the Linux server status code

Example, PHP gets the Linux server status code. function Get_used_status () { $fp = Popen (' top-b-N 2 | grep-e "^ (cpu| mem| Tasks) "'," "R");//Get a moment of system CPU and memory usage $rs = ""; while (!feof (

This is the package of my MVC framework Actioncontroller

This is the package of my MVC framework Actioncontroller /* * Mst_library v3.1 * @autohr Janpoem */ if (!defined (' In_mst_core ')) Exit (' Mst_actioncontroller can\ ' t be include single! ');

The code comes from PHP design mode.

The code comes from PHP design mode. ? /** * from the sixth chapter of PHP design mode: Decorator mode * * Decorator design mode is suitable for the following work situations: Demand changes are fast and small, and

The use of learning error_reporting

Error_reporting in the use of PHP programming frequency, presumably everyone is very clear, this article introduces the usage of error_reporting, for everyone to learn the reference. If the parameter level is not specified, the current error levels

The caching technology under PHP

Common caching techniquesdata Cache : The data cache refers to the database query cache, each time access to the page, will first detect the corresponding cache data exists, if not exist, connect the database, get the data, and the query results are

Share discuz PHP to prevent SQL injection functions

Share the SQL anti-injection letter of the Discuz forum Number, good writing. $magic _quotes_gpc = GET_MAGIC_QUOTES_GPC (); @extract (Daddslashes ($_cookie)); @extract (Daddslashes ($_post)); @extract

Calculates the interval between Monday and Friday within a year

Years $year = Date ("Y"); $beninTime = Mktime (0,0,0,1,1, $year); $endTime = Mktime (0,0,0,1,1, $year + 1)-1; $weekArray = Array (); $isBegin = true; $forTime = 0; for ($time = $beninTime; $time

Get field information for a table using PHP

To get the field information in PHP, you can use the following function : Mysql_fetch_field () Mysql_num_fields () Mysql_list_fields () mysql_field_flags () MySQL _field_len () Mysql_field_name () Mysql_field_type () mysql_field_table ()The

Learn the usage of PHP serialize () and Unserialize ()

Serialize () and unserialize () are explained in the PHP Manual: Serialize-generates A storable representation of a valueserialize-produces a representation of a value that can be storedUnserialize-creates a PHP value from a stored

PHP generates random code for a segment

rfc

/* * Description: Generate random codes and display random codes graphically. */ $ViewRandomCode = Mt_rand (1000,10000); Session_Start (); $_session[' checksum '] = $ViewRandomCode; function Set_4pixel ($r, $g, $b, $x, $

Database connection Operation class

Database connection Operation class Class MySQL { Private $_link; Public function __construct ($dbhost, $dbuser, $dbpassword, $dbname, $charset = ' UTF8 ') { $this->_link =

PHP does not use the Open source class library to export MySQL data to an Excel file

Output Excel file header, you can replace user.csv with the file name you want Header (' Content-type:application/vnd.ms-excel '); Header (' content-disposition:attachment;filename= ' user.csv "'); Header (' cache-control:max-age=0 ');

php5.3 method for fast URL rewriting in the above version

#--------------. htaccess start--------------- Rewriteengine on Rewriterule!\. (js|ico|gif|jpg|png|css|swf|htm|txt) $ index.php Php_flag MAGIC_QUOTES_GPC off Php_flag register_globals off #--------------. htaccess

A more comprehensive intercept function (more for the analysis of the collected content)

/* Capture intercept function, mainly used to analyze the collected content Getcon-Remove HTML characters and remove spaces after interception Getcon2-Simply intercept and return the intercepted content directly. Parameters:

A handy php file upload processing class

//------------------------------------- File Description: File Upload processing class File Author: Jesse Lee //------------------------------------- Class Upload { var $dir; Attachment Storage Physical Directory var

Total Pages: 5208 1 .... 1657 1658 1659 1660 1661 .... 5208 Go to: GO

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.