trigger.php 312 B

123456789101112
  1. <?php
  2. /**
  3. * These two snippets demonstrates triggering an event and how to register for
  4. * that event.
  5. */
  6. $object = new ElggObject();
  7. elgg_trigger_event('test', 'example', $object);
  8. // elsewhere a handler could be registered by saying
  9. elgg_register_event_handler('test', 'example', 'example_event_handler');