If I am in the middle of a method in an ActiveRecord object or a
controller how can I just print something out to the screen and either
keep going or exit immediately?
If I am in a controller I can just generate some text and:
render :text => “my debug output”
But it would be nice to print something out to the output buffer and
then continue on. Additionally, if I am inside an ActiveRecord, I just
want to print something out and just die. In PHP I would just do a
print_r() on some data and then call die(). Is there similar “ghetto”
debugging facilities availabe?
On Jun 11, 2006, at 9:50 PM, William Langshaw wrote:
But it would be nice to print something out to the output buffer and
then continue on. Additionally, if I am inside an ActiveRecord, I just
want to print something out and just die. In PHP I would just do a
print_r() on some data and then call die(). Is there similar “ghetto”
debugging facilities availabe?
Thanks!
breakpoint is your friend…
–
Robby R.
Founder & Executive Director
PLANET ARGON, LLC
Ruby on Rails Development, Consulting & Hosting