5
votes
Accepted
before_channel_entry_save hook
This was driving me insane but I've figured it out.
You need to edit the $entry object (1st parameter of the function) in order for this to work. You can, however, use the 2nd parameter, $values, for ...
2
votes
Custom add-on accessing method from another custom add-on …
I agree with the advice provided by Brian in EECMS Slack. You can do this:
require_once PATH_THIRD . 'your_addon/somefile.php'
$someFile = new SomeFile();
$someFile->method();
2
votes
Accepted
Using the cp_custom_menu hook
The cp_custom_menu hook, although sounding like it will automatically add an item to the menu, in fact just adds your add-on as a new option when creating a custom menu via Settings -> Menu Manager ...
2
votes
Accepted
Updating hooks from v2 to v4
There were certainly several extension hook changes with the arrival of EE3, possibly with EE4 too, so you may well need to update the naming of the hooks in your addon.
You can find a complete list ...
1
vote
Expresso store : add on, hook store_order_complete_end creates order id+1
Using $this->extensions->last_call in the hook turned out to be redundant.
1
vote
Accepted
How to get data from a hook?
At the end of hook "channel_form_submit_entry_end" it is using the Channel Form Class so $obj->entry['entry_id'] a class property which is not available.
Good news is you can use the method $obj->...
1
vote
Hook when member updates password
These what you are after? It appears these are planned for conversion to services down the road. But should still work now.
https://docs.expressionengine.com/latest/development/extension_hooks/...
1
vote
Using the cp_custom_menu hook
add this at the end of
public function cp_menu_array($menu)
{
if ($this->EE->extensions->last_call !== FALSE)
{
$menu = $this->EE->extensions->...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
hook × 80extension × 24
expresso-store × 16
add-on-development × 13
module × 7
ee2 × 6
members × 4
sessions × 4
add-on × 3
email × 3
comments × 3
cartthrob × 2
templates × 2
solspace-freeform × 2
solspace × 2
channel × 2
php × 2
ee3 × 2
forms × 2
status × 2
postmaster × 2
datagrab × 2
language × 2
session-end-hook × 2
channel-entries × 1