Re: [Phpslash-devel] Very minor debugging suggestion for lib.resources.php
Brought to you by:
joestewart,
nhruby
From: Joe S. <joe...@us...> - 2003-07-10 17:00:57
|
On Thu, Jul 10, 2003 at 10:57:39AM -0400, Mike Gifford wrote: > Howdy, > > in lib.resources.php, the function pslNew could be slightly easier to > debug in the future if the declared classes could be output more easily: > > else { > // print_r(get_declared_classes()); > pslError("No such class: $class"); > return false; > } > > I was trying to figure out why the heck pslNew wasn't working for a new > class I was developing and finally figured out that I hadn't quite > changed the class name correctly.... > > You can't pass arrays to the debug function very well.. I suppose you > could serialize them so > debug('List of classes',serialize(get_declared_classes())); > > In anycase just a thought.. > Hey Mike, debug() should have no trouble outputting arrays. This works fine for me: debug("declared_classes", get_declared_classes()); What is the value of debug.max_recursion_level in config.ini? debug.max_recursion_level = 10 If you add a test like this do you get the full array displayed? debug("_PSL", $_PSL); Joe > Mike > -- > Mike Gifford, OpenConcept Consulting > Free Software for Social Change -> http://www.openconcept.ca > Featured Client: CUPE National -> http://www.cupe.ca > Whoever controls the media-the images-controls the culture - A. Ginsberg > |