MrBaseball34 Posted August 23, 2010 Share Posted August 23, 2010 I wrote this function, placed it in the Tools class: /** * Logs message to ps_debug_table * * @param $module string - module where error occured * @param $msg string - message to log */ static public function DebugLog($_mod, $_msg) { Db::getInstance()->Execute('INSERT INTO `'._DB_PREFIX_.'debug_table` (proc_id, debug_output) VALUES ('.$_mod.', '.$_msg.')') or die(self::displayError()); } And I call it like this, say from Products.php: Tools::DebugLog('Product', 'In Get Products()'); However, nothing is getting inserted into the ps_debug_table.Any ideas as to why? Am I doing something wrong here?I've tried using the FirePHP code from ecartservice.net but it didn't work, either, I got no messages logged. Link to comment Share on other sites More sharing options...
MrBaseball34 Posted August 23, 2010 Author Share Posted August 23, 2010 Ok, I have it down now. It was just a matter of where to place everything. Link to comment Share on other sites More sharing options...
AffordableFiberOptics Posted August 24, 2010 Share Posted August 24, 2010 Is there a way to turn logging on? Link to comment Share on other sites More sharing options...
MrBaseball34 Posted August 24, 2010 Author Share Posted August 24, 2010 This is a custom feature that I built in myself. I don't have a flag for that as of yet. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now