5093 Posts in 1516 Topics by 1113 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 252 Views |
-
Newbie - do extension hooks exist?

21 February 2012 at 8:55am
Hello there!
I'm a Silverstripe noob and have been tasked with creating some custom functionality with an existing site (v2.3.3). Basically I need to extract data from the database at certain points and post it to webCRM's API.
Forgive the probably obvious question but does Silverstripe come with extension hooks that I can use at certain points to do this? This would need to be done upon completion of a member registration, on updating the member profile and on successful completion of a worldpay transaction.
I am only just starting to get to grips with how SS works so any pointers would be greatly appreciated.
-
Re: Newbie - do extension hooks exist?

22 February 2012 at 5:53pm
What hooks are you wanting? Popular ones are onBeforeWrite() and onAfterWrite() (when saving objects to the database).
http://doc.silverstripe.org/sapphire/en/topics/datamodel#onbeforewrite
You can find any hooks in core by looking for $this->extend() of which their are quite a few!
-
Re: Newbie - do extension hooks exist?

23 February 2012 at 4:36am
Hey Willr,
Thanks for the reply. At the moment I'm not certain what hooks I need, but your reply certainly points me in the right direction so I can hopefully figure that out
Many thanks!
| 252 Views | ||
|
Page:
1
|
Go to Top |


