Debugging C5
Permalink
Been working through a couple of sticky problems with C5 and found a need for a relatively simple debug tool / strategy.
Many regular debuggers seem a bit trick to set up on a live c5 without breaking too many things. We spent a bit of time playing around and thought we might share the results
In the end we settled on using Krumo (Google) which is best downloaded and installed wherever your PHP includes are stashed, so you can call it up from anywhere
Also copy a copy of the krumo folder to a point accessible to your browser and set up the ini file IN THE INCLUDES DIRECTORY to point to this url
As a test, go to the header of your chosen theme file and include Krumo
- Needs to be inserted in a visible part of the page -- like just under the body tag
Then try out some krumo things
You can insert that snippet anywhere that there is visible comment and Krumo will pop up a bar
There's lots more -- we are just posting to see if there is interest.
Post back if you want more details
Prema
Many regular debuggers seem a bit trick to set up on a live c5 without breaking too many things. We spent a bit of time playing around and thought we might share the results
In the end we settled on using Krumo (Google) which is best downloaded and installed wherever your PHP includes are stashed, so you can call it up from anywhere
Also copy a copy of the krumo folder to a point accessible to your browser and set up the ini file IN THE INCLUDES DIRECTORY to point to this url
As a test, go to the header of your chosen theme file and include Krumo
<?php include("class.krumo.php"); ?>
- Needs to be inserted in a visible part of the page -- like just under the body tag
Then try out some krumo things
<?php krumo::backtrace(); // gives a very cool back trace of everything up // until this point. krumo($this); // Picks up the view and allows you to see all the //variables which have been set ?>
You can insert that snippet anywhere that there is visible comment and Krumo will pop up a bar
There's lots more -- we are just posting to see if there is interest.
Post back if you want more details
Prema