Eduardo G. Posted April 22, 2010 Share Posted April 22, 2010 Hi all, I'm developing some modules to add extra funcionality to whmcs. I use them as Addon Modules. How should I send an email from my module? I want to create email templates so my module can use them to send emails, but found nothing about email funcions. How are you managing this? Thanks 0 Quote Link to comment Share on other sites More sharing options...
HerrZ Posted April 22, 2010 Share Posted April 22, 2010 sending email templates by using the api http://wiki.whmcs.com/API:Send_Email 0 Quote Link to comment Share on other sites More sharing options...
Eduardo G. Posted April 22, 2010 Author Share Posted April 22, 2010 Thanks, HerrZ. I'm trying to create these modules without the usage of an API, so any user can just upload them and use them, without the need of enabling api accessn creating api user and configuring module. IMHO, I think API is great for external apps, but not so much for internal modules, don't you agree? Are module developers using always API funcions? should I use them? isn't it too complicated using and configuring api access for extra modules? am I wrong? 0 Quote Link to comment Share on other sites More sharing options...
HerrZ Posted April 22, 2010 Share Posted April 22, 2010 i agree and i dont explored yet which core function sends out the email templates by default. for sending just the templates the api is theoretical a big lump of code for sure. but its easy to use like a swiss army knife. i built me an whmcs api class. so i can easily call any api function anywhere in my code. no matter it is standalone, or cms or whmcs system. concluding it is a little bit oversized but its IMHO the best solution as long the core is encoded Are module developers using always API funcions? no and you are not wrong and i think the way you are thinking is in a good code ethic. hope you understand my sentences in "english". merci. 0 Quote Link to comment Share on other sites More sharing options...
Eduardo G. Posted April 22, 2010 Author Share Posted April 22, 2010 Thanks very much for your answer, I'm glad to see that my point of view is not far from others. Making an api-class is a great idea, but it still needs api enabled to use the modules I made. Hmm.. open source code, I miss you... Anyway thanks for sharing your opinion with me ;-) 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.