File tree Expand file tree Collapse file tree 1 file changed +69
-2
lines changed
Expand file tree Collapse file tree 1 file changed +69
-2
lines changed Original file line number Diff line number Diff line change 1- # simple-php-debuging
2- Simple PHP debuging tools and utils
1+ > Simple PHP debuging tools and utils
2+
3+ Simple handy manual debuging utils
4+
5+ ## Install
6+
7+ ```
8+ composer require trash07/simple-php-debuging
9+ ```
10+
11+ ## Usage
12+
13+ * Dumping
14+
15+ ``` php
16+ $people = array('marc', 'john', 'liman');
17+ // what is the structure of $people ?
18+ _dump($people);
19+ ```
20+
21+ * Debug
22+
23+ ``` php
24+ $info = array('marc', 'john', 1);
25+ // readable $info array echo
26+ _debug($people);
27+ ```
28+
29+ * Stopping execution
30+
31+ ``` php
32+ // simple stop
33+ _stop();
34+ // stop with message
35+ _stop("Sorry we must stop");
36+ ```
37+
38+ * Testing condition
39+
40+ ``` php
41+ $r = 10; $s = 11;
42+ // test the condition of the if statement
43+ _condition($r > $s && $r < $s);
44+ if ($r > $s && $r < $s) {
45+ // do something ...
46+ }
47+ ```
48+
49+ ``` php
50+ $r = 10; $s = 11;
51+ // test the condition of the if statement with message
52+ _condition($r > $s && $r < $s, "The $r, $s equality testing if");
53+ if ($r > $s && $r < $s) {
54+ // do something ...
55+ }
56+ ```
57+
58+ * Seing if a line was executed
59+ ``` php
60+ // simple test
61+ _line();
62+ // _line() with message
63+ _line("Are we realy here ?");
64+ ```
65+
66+
67+ ## License
68+
69+ GPL-3.0 © [ trash07] ( https://it-consulting.890m.com )
You can’t perform that action at this time.
0 commit comments