asprin
Active member
I have some controllers used by my add-on at the following locations:
If I were to have a helper/utility class that would do some common tasks such as convert timestamp to local, validate something etc..where can I place that? Would the following be a good option?
If so, how would I reference that class/method in my controller functions?
Code:
src/addons/FC/Pub/Controller/FileA.php
src/addons/FC/Pub/Controller/FileB.php
src/addons/FC/Pub/Controller/FileC.php
If I were to have a helper/utility class that would do some common tasks such as convert timestamp to local, validate something etc..where can I place that? Would the following be a good option?
Code:
src/addons/FC/Util/MyClass.php // using the folder name as Util as I see the same being used in core XF framework
If so, how would I reference that class/method in my controller functions?