AbanteCart Development > Development Help Needed

Is it possible to hook functions in controller?

(1/2) > >>

yonghan:
Hi,i would like to ask if it's possible to hook functions in controller?i.e i would like to extend add function in customer manage address controller to use other styles.insted of directly edit the controller or using javascript.thanks a lot.

abantecart:
You can hook to any controller in the beginning and at the end. You can also have pre and post controllers

Check this manual:
http://www.abantecart.com/document_wiki/index.php/AbanteCart_Extension’s_Developer_Guide#Hooks

abolabo:

--- Quote from: yonghan on June 26, 2014, 07:13:03 AM ---Hi,i would like to ask if it's possible to hook functions in controller?i.e i would like to extend add function in customer manage address controller to use other styles.insted of directly edit the controller or using javascript.thanks a lot.

--- End quote ---

of cource.

read this first
http://www.abantecart.com/document_wiki/index.php/AbanteCart_Extension%E2%80%99s_Developer_Guide#Hooks
and also you can open some extension's file with hooks for ex. default_pp_pro/core/default_pp_pro.php to look...
Also we have developer tools to generate extension https://github.com/abantecart/developer_tools_extension
You can build your own extension very fast.

yonghan:
Thanks a lot for the replies,i'll take a look at the pre and post controller example from existing extensions.

yonghan:
Hi abolabo,my question is not clear enough.What i would like to do is hook function i.e insert function in storefront/controller/pages/account/address.Is it possible to do that?Thanks

Navigation

[0] Message Index

[#] Next page

Go to full version
Powered by SMFPacks Social Login Mod