This article describes how to view the array information by using the custom function dump in php. The specific example is as follows.
This article describes how to view the array information by using the custom function dump in php. The specific
This article describes how to view the array information by using the custom function dump in php. the specific example is as follows. I hope it will be helpful for you for a long time. it is much easier to use than the built-in var_dump in php.
Provides various official and user-released code examples and code reference. You are welcome to exchange ideas and learn from new students.
/*** General custom tags* Usage:* 1: Load*
* 2: Call*
* {$ V. id} -- {$ v. name}
*
* Note:* 1.
This has been around for a long time and is much better than var_dump in php.Copy codeThe Code is as follows:Function dump ($ vars, $ label = '', $ return = false ){If (ini_get ('html _ errors ')){$ Content = " \ n ";If ($ label! = ''){$ Content. = "
This is very early, more than the Var_dump with PHP.
Copy Code code as follows:
function dump ($vars, $label = ', $return = False) {
if (Ini_get (' html_errors ')) {
$content = "\n";
if ($label!= ') {
$content. = "{$label}: \n";
}
File operations
Open action
Io.open (file, mode= ' R ', Buffering=-1, Encoding=none,errors=none, Newline=none, Closefd=true, Opener=none)
Returns a file object (Stream object) and a file descriptor. Failed to open file, return
Several common php functions, such as empty removal, grouping, and debugging of array functions. Dump () uses arrays in array format. it is helpful for debugging functiondump ($ vars, $ label, $ returnfalse) {if (ini_get (html_errors) {$ contentpren;
Several common unempty, grouping, and debugging array functions. Dump () uses arrays in array format to debug functiondump ($ vars, $ label, $ returnfalse) {if (ini_get (html_errors) {$ contentpre; if ($ label !) {$ Content. dump () uses arrays in
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.