Welcome Guest, Not a member yet? Register   Sign In
Can't 'echo' or 'print_r' anything within my Model
#1

[eluser]KeyStroke[/eluser]
Hi,

I have a Model where one of the functions produces an error (an invalid insertion to the database). I'm trying to debug it by echoing or print_r'ing some variables that precedes the database call, but everytime I refresh the page I get only the database error, nothing else.

I tried then using 'redirect()' before the erroneous database insertion to see if my application even goes there, and it does! but it's refusing to print anything I want.

Any ideas what's wrong?
#2

[eluser]thecancerus[/eluser]
try putting 'exit' after your print_r or echo...
#3

[eluser]KeyStroke[/eluser]
oh I just found out that error reporting in PHP was off. Sorry.




Theme © iAndrew 2016 - Forum software by © MyBB