Jump to content

Hooks


jka

Recommended Posts

BSmither et-all,

We are trying to trouble-shoot a newly added plugin. We verified ...

1. the plugin is enabled
2. the hooks are enabled.
3. the db table also show the hooks_name set to '1'

However the hooks functionality is not working. Any guidance to debug the hook whether it is loading and add debug messages? This is in the admin/product screen.

Thanks.

Link to comment
Share on other sites

There are a few approaches to getting debug/diagnostic data:

1. Add the following statement whenever you need to see the value of a passable-by-reference variable:

$GLOBALS['debug']->debugTail($variable_to_examine, 'key');
where the key could be something like:  'orders.index.inc.php_510'
This will show as a heading in CubeCart's debug section of the page.

2. Add the following statement whenever you need a phrase to be seen:

$GLOBALS['debug']->debugMessage("Just entered the hook: " . $hook);
In the debug section of the page, there will be Messages listed near the bottom.

3. I have developed my own diagnostics module. It allows for program code tracing.

Edited by bsmither
Spelling
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...