CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Developer Discussion (Moderator: Donald Lobo) »
  • debug a hook
Pages: [1]

Author Topic: debug a hook  (Read 430 times)

ñull

  • I’m new here
  • *
  • Posts: 10
  • Karma: 0
  • CiviCRM version: 4.6.8
  • CMS version: Drupal
  • MySQL version: 5.5.41
  • PHP version: 5.4.39
debug a hook
September 03, 2015, 09:29:15 am
I'm a beginner and hacker in CiviCRM development and want to create a Extension module to manipulate the permissions. I'm still in the phase where I study and experiment. Following instructions I have made an empty module with civix and was able to install / enable it.

To study the hook aclWhereClause a created the

Code: [Select]
function permissions_civicrm_aclWhereClause( $type, &$tables, &$whereTables, &$contactID, &$where ) {
 $args=func_get_args();
 CRM_Core_Error::debug('aclWhereClause_arguments', $args,false,true );
}

I don't see displayed the promised debug messages. Questions:
  • When would this hook normally be called? It seems not to be called at all. Is it called when logged in as main administrator?
  • What would be the (better) way to study hooks like this in general? I want to know what is in the arguments while using the CRM.
  • Generally, what would be your advice when your read this?

Thank you!
« Last Edit: September 03, 2015, 09:52:00 am by ñull »

petednz

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4899
  • Karma: 193
    • Fuzion
  • CiviCRM version: 3.x - 4.x
  • CMS version: Drupal 6 and 7
Re: debug a hook
September 03, 2015, 12:04:46 pm
Hi - most questions are being asked on StackExchange now so please re-ask it over there.
Sign up to StackExchange and get free expert advice: https://civicrm.org/blogs/colemanw/get-exclusive-access-free-expert-help

pete davis : www.fuzion.co.nz : connect + campaign + communicate

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Developer Discussion (Moderator: Donald Lobo) »
  • debug a hook

This forum was archived on 2017-11-26.