Welcome To Snipplr


Everyone's Recent PHP Snippets Tagged debug



« Prev 1 2
Debugger analog for PHP: debugger console_log ().
0 4197 posted 7 years ago by cerxx
In certain cases, it is useful to display additional information in a journal that does not report an error, but simply helps in writing your own code. For this PHP provides the function error_log (). This function does not provide formatting, so yo...
0 4109 posted 7 years ago by cerxx
A little pile of functions I use for implementing a nice var dump alternative.
0 2634 posted 13 years ago by philsown
I use this primarily for debugging purposes. This simply takes an array and creates an expandable item that prints the array out in a \<pre\> wrapping, making it easy to read. Very basic snippet.
0 2809 posted 13 years ago by ringo380
1 1678 posted 14 years ago by beneberle
Print Debug Information (Exibe as informações de depuração)
0 2590 posted 14 years ago by cdohost
a more useful way of printing php arrays in a nice readable format and able to decode serialized and json_encoded strings.
0 2734 posted 14 years ago by liamchapman
0 2696 posted 15 years ago by pacifists
0 2527 posted 15 years ago by kendsnyder
0 1594 posted 15 years ago by kendsnyder
0 2463 posted 15 years ago by fadehelix
just copied-pasted it so that it can also reside on Sniplr
0 2287 posted 15 years ago by dmistriotis
1 1907 posted 15 years ago by jmiller
I'm originally a sys admin and i love "tail - f /var/log/*" ... so i created a similar function in PHP that will allow me to view in real time what classes/functions/files/lines of my code is being run... The usage is really simple, just set a glo...
1 3525 posted 15 years ago by sadus
0 1076 posted 15 years ago by iusik
You can get the last query by using the following code. Insert the first line before the query and TYPO3 will store each query. You can get the last query with the second line.
3 1960 posted 15 years ago by pogosheep
This is the PHP code to debug any variable ..
1 1649 posted 15 years ago by xkeshav
When working in PHP I sometimes want to know exactly what is in a variable. This is easy enough to find out, but having this function around it is even easier, as it includes the HTML pre tag making it easier to read, and it allows you to choose how...
1 1755 posted 15 years ago by Sverri
1 1672 posted 15 years ago by chrisdpratt
Add snippet in BaseFormPropel.class.php
1 2069 posted 16 years ago by skwok
to
0 1294 posted 16 years ago by mware1205
How to replace sleep(2), for your PHP code. Ideal testing hosting/dns ping.
1 1995 posted 16 years ago by nicolaspar
A simple replacement for print_r or whatever you use to display debug info.
2 1763 posted 16 years ago by PeteW
displayed filename and line number. //normal use d( $arg ); //some arguments d( $arg1 , $arg2 , ... );
0 1288 posted 16 years ago by ikimozu
Drupal helper function to debug a table. Returns the contents and some explanation of a database table in a rendered format (HTML table). **NOTE** You REALLY do not want to put this function behind any kind of menu_callback and/or on other pages....
1 2746 posted 17 years ago by berkes
For when I catch a bad case of stupid and forget how to write simple php and I need to put the training wheels back on. Drop this in before the closing body tag on a php page to see a list some of what is happening when the page loads.
0 1213 posted 17 years ago by inkdeep
« Prev 1 2