I see there is an undocumented event called
onBeforeMessageCompile in the Contact Form plugin source:
Craft::import('plugins.contactform.events.ContactFormMessageEvent'); $event = new ContactFormMessageEvent($this, array('postedMessage' => $postedMessage)); craft()->contactForm->onBeforeMessageCompile($event);
My questions are:
- How does one use this event? What can it be used for? and
- Why is an
$eventobject being instantiated at this point in the controller?