You can require files in PHP in the same way as without Magento, so you can use require_once if necessary. If you want your code to be cleaner, you can put it in the /lib folder in Magento, as it is a system library. I'm not sure if this is included in the default inclusion path, so you may have to bother with the requirement.
For cleanliness, you can also create a wrapper around this code and use Magento models / helpers to manage them.
Hope this helps!
Thanks Joe
source share