I wrote a function as a beginner in PHP. The content is as follows:
Running error (as shown in ):
The system prompts "Conversion error". How can this problem be solved ??? Nothing to write ,,,
After careful observation, I found that when I
Although xdebug is available, log or var_dump is usually used for debugging.
I often want to know the current variable status when executing a certain point. I came back today and found the following information on the PHP Official Website:
ArticleDirectory
Syntax
Definition and usage
The substr_replace () function replaces one part of the string with another. Syntax
Substr_replace (string, replacement, start, length)
Parameters
Description
From http://vianoz.javaeye.com/blog/650791
Configure PHP in IIS 5.1 of the XP system so that IIS 5.1 of XP can also run PHP programs.
XP, as a common system, cannot be used as a server.
However, for debugging some ASP, PHP website programs are still
1. Add a string function:
Number_format (number, decimals, decimalpoint, separator)
Parameters
Description
Number
Required. The number to be formatted.If no other parameter is set, the number is formatted
I bought a VPS at DIAHosting, which comes with PHP5.1.6. I want to install wordpress. However, due to the newer version, PHP is required to be later than 5.2, So I installed PHP5.3.20
------------------------------------------------------------------
Set_time_limit favoritesSyntax: void set_time_limit (int seconds)
Note:
Set the number of seconds that a program can run. If the time limit is reached, the program will return an error. The default limit time is 30 seconds. The value of
Definition and Usage
Definition and usage
The str_replace () function replaces some characters with some other characters in a string.The str_replace () function is used to replace a substring with another string (Case Insensitive ).
This function
Definition and usage
Definition and usage
The defined () function checks whether a constant exists.The role of the defined () function is to checkConstantWhether it exists.
Returns true if the constant exists, or false otherwise.If the constant
1. Use PHP to write a simple query, find all the content named "Zhang San" and print it out.Table Name UserName Tel content dateZhang San 13333663366 graduated from college-10-11Michael Zhang graduated from 13612312331 undergraduate
Install Memcache in linux:
1. Download the linux version of memcache. Note that memcached uses libevent as the event driver. Therefore, install libevent first.2. Install pecl: memcache.
Install with pecl command line tool:Pecl install memcache
Or
PHP itself does not support multithreading, multi-process support is not particularly good, online to find a multi-process code (http://jasonyu.cn/html/2010/294.html), write a test program simple test a bit, you can run, however, it is far from
Finally, I have a chance to get in touch with PHP. I can use a few words that my friends often say !!!
It is true that PHP and C are very similar, but their statements are relatively simple. I wrote a few small examples and kept thinking about how
Document directory
Syntax
Syntax
Define ()A function defines a constant.
Constants are similar to variables, except that:
define(name,value,case_insensitive)
Parameters
Description
Name
Required. Specifies the name of
Regular Expressions are an important element in program development. They provide strings used to describe or match text, such as specific characters, words, or expressions. However, in some cases, it is complicated and time-consuming to use a
The following functions can be used to replace the built-in is_writable function of php:
// It can be used to replace the built-in is_writable function isWritable ($ filename) {if (preg_match ('/\/$/', $ filename) of php )) {$ tmp_file = sprintf ('%
I recently saw another new version of PHP download on the PHP official website, so I went up to find the version For Windows, but I was dumpfounded and gave four versions in total, VC9 x86 Non Thread Safe, VC9 x86 Thread Safe, VC6 x86 Non Thread
Looking at the unsatisfactory Erlang string operations, why not try to simulate some basic operations on php Strings?
Recently, I have been playing Erlang for some time. I 'd like to write down two of them first and then complete them when I have
1. proportional reduction2. The specified thumbnail size is required.3. The source image can be cropped, but the center must be in the window.
"; if ($ SetW-$ nw = 1) {$ nw = $ SetW ;} if ($ SetH-$ nh = 1) {$ nh = $ SetH;} echo "+ corrected 1 pixel:
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