From e9196b94006e73771d406df080410fb4b31820d0 Mon Sep 17 00:00:00 2001 From: Amigo <49749100+aamigo@users.noreply.github.com> Date: Wed, 12 Jun 2019 17:14:19 +0200 Subject: [PATCH] Updated 025 How to use email helper in your components (markdown) --- ...-to-use-email-helper-in-your-components.md | 37 ++++++++++++++++++- 1 file changed, 35 insertions(+), 2 deletions(-) diff --git a/025-How-to-use-email-helper-in-your-components.md b/025-How-to-use-email-helper-in-your-components.md index a0db175..4e0f31f 100644 --- a/025-How-to-use-email-helper-in-your-components.md +++ b/025-How-to-use-email-helper-in-your-components.md @@ -20,5 +20,38 @@ Even those fields you will need to look at the code to know what their names sho In your component there is a options area, I'm going to open that. Once it's open your see there is a mail configuration and a DKIM area. [00:03:45](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h03m45s) Let's open the mail. You will see that it has the mailer status. So it's either set to off, then no emails will go out, or to on. -??? -If it set to on you can decide whether you want to override the global function, the global variables. now the global variables are set in your Joomlas components Global area [00:04:10](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h04m10s) So you would go to Global configurations And then You'd go to System No sorry It's server And then there's this mail settings here Ok Now these are the main or the the global settings that will be used in the in any component that Does not add [00:04:40](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h04m40s) These settings in their config So if you didn't create Those Fields and added it to your component but you ticked the the button to sort of add the helper Class to your component Then That means that it will basically fall back to these settings in your Joomla default Area So Just that you know And these are the values that you need to overwrite if you want your [00:05:08](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h05m08s) Component into some way to use other PHP mail or other send mail or Other What's the other one SMTP Values than that of the global you need to set it here And That is basically what this area can do So you use Global it falls back to the Joomla Global Otherwise you can overwrite it on this level And send it out In a way that is [00:05:38](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h05m38s) What you would like The DKIM area Is there more advanced area which basically allows you to overwrite Overwrite sorry not overwrite to encrypt And secure email sent out from you to authenticate that it was really you that send it This is very helpful to sort of show your the people that receive these emails that it's not Spam and it's really comes from you it's more advanced I would encourage you to read up on it these are the values Usually would be required to be added private key a public key And obviously these type of areas here If this is set to no obviously it will not be used if it set to yes please ensure to add the values [00:06:25](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h06m25s) Otherwise it still will not be used Ok So that's basically the values that you needs to still create Component does not do this for you You need to do it I could possibly foresee that In the future we might add this If you tick the helper class it adds these values for you But even then if you have done it manually We'll make sure that it doesn't add in twice [00:06:51](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h06m51s) So as long as These values obviously be the same Names we will know actually a Somehow identify that And then not Add them dynamically So to avoid clashes But for the meantime it's not automatically being added and so you need to do that manually if you want it To be there if you don't like I've said before It will fall back to the Joomla Global [00:07:15](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h07m15s) So to explain that you on the code level Basically it gets from the configuration The mailer function And then it checks whether it's global If it is global Then It Implements Joomlas Values If it's not Global it implements your components values [00:07:38](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h07m38s) And That is basically what it will do Now you can read through the code But the most important area really is this area To know what is all the various Options that you have in the signature To send out Mail So it's able to really send out a lot of mail but Nonetheless You're also need to consider [00:08:04](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h08m04s) You know Your servers own limitations Since we obviously don't want you to spam people We do not Overwrite those values. We are simply using the Joomla default Helper Joomla sorry jmailer And it is been extended from another class And so there are a lot of features and here And if you wanna know more about them you can read up on on obviously the jmailer [00:08:35](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h08m35s) Class from Joomla As well as read through this code here and see how we implemented These are the dkim values that you would need And in your In your component To be able to use the dkim encryption But you could also read up on this and check out this function here up till there In its way that it's implementing these features It obviously is adding it to the mailer and most of the work is done in the mailer [00:09:05](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h09m05s) So it's basically adding the data to the mailer and the mailer takes care of the rest Ok and so here it sends it off And if there is an error So let's say for some reason it didn't you know work out well Then it shakes whether Your Component Helper class So your component has a helper class it's just this file here [00:09:31](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h09m31s) Even has a storemessage Variable or method So if we were to go check this You see that there is the storemessage method In the helper class this is a custom method that I wrote now you can write it anywhere you like But this signature should be the same Ok so here Is the same signature you'll see it [00:10:00](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m00s) So basically this area that And that is dynamically updated to your component So it uses your component name here and your component name there But this store message Is basically Not You cannot change that but it takes to send email the recipient the subject the body to text only in the mode and it's says That it's email So you can have different types so if you look at the the method The type can be anything [00:10:30](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m30s) We are obviously wanting to do different things on different type so if we send an SMS and we didn't Fail You wanna store the message if we did this or that So this this kind of feature Is it only used when something didn't work But also if it worked If it was sent It's gonna store it So it's a way to store the message So that you can [00:10:57](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m57s) Maybe let your user go If they login They can see messages sent to them and this kind of stuff So this is what the store message does and as you see it's whole huge custom Method that I wrote And it does different things for different You can update it in change it pause the video copy it down don't really matter Just if you realize this is actually something you write up yourself you just need to make sure that that part is the same The rest is up to you Now you deal with it ok so that is really implementing the learning manager emailer [00:11:35](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h11m35s) In your component Maybe I should show you where I implemented at least In one area ok let me do that Ok so I have this component called job tracking system if I open it up You'll see that it actually has that function Adding the helper email it's got it selected you see there add helper Set it to on Then the view in which we are using the email method is the job or the view Basically we want to email the client I did job order [00:12:21](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h12m21s) When when it's created So let me show you how I implemented it there So here is the job order And I would basically then Click on This area here email now I can update that to whatever email I like Testing @ [00:12:45](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h12m45s) vdm.io or something Just send it in to Nothing And Then once the email has been sent It actually let's me know See there in the it says email was sent successfully So That's basically what the emailer does it just this button it sends this Document [00:13:11](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h13m11s) To my Client And also if I want to send it to my store The people that does the job I could also do that here I'm not gonna explain to you The reality of taking this content adding it to the email and sending it That I would suspect you need to know and you need to learn or study to do that yourself I'm I'm simply explaining to you how to use the email helper class So we will go to the code and I'll show you how I do it and [00:13:45](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h13m45s) Mostly Maybe I'll give you some pointers but I won't go into detail About how that is done Ok so let's go to the to the code So here we are in the job order So first thing here is obviously some JavaScript So there's the send email function and Gets a set of values And then it basically gives it over to the send Email server function which sends it as a J object [00:14:20](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h14m20s) Sorry a json request to the server The send Email is the Task And when it gets a response that's when you get the notification Ok so that's Simply the JavaScript of it So now if we go to PHP Previous Tutorials we explain how to use the Ajax class I'm gonna just touched on it briefly [00:14:47](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h14m47s) You basically have your input here This is where you put set up your controller Let me show you that So you'll see in your controller There is this send email Class that's what basically was defined And this field here And you see that there is Basically three variables And they are [00:15:12](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h15m12s) Should be filtered in this way and they are fast over to these methods And you should be logged in user So if you look at the code again it basically this is the task down here it triggers the task It checks for those values and then passes it over to This method which is in the Model is a model So we go to models Ajax So here is the the model let's just scroll down to the send email So here is the send email and this again [00:15:47](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h15m47s) Is a custom Script So if I was to go back here I Close this You'd see there's the in this Ajax method is a lot I mean look at that you can see that scroll down way down is a lot of other custom methods here But this is another custom method I've written Call send mail gets the mail the HTML to type It it does the necessary Cleansing and whatever [00:16:14](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h16m14s) And then It Basically Over Here We're calling the email helper We using the send method we Passing the valuables and we Set the result in here And if the results is obviously true [00:16:38](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h16m38s) We will let the user know otherwise we give him the error ok so that That is the The short end of it I'm also using this email body to help me build the the email because I want to Make sure that it's got all the necessary HTML and stuff so you can Pause this video and type that out if you like But this is the email body that I usually use and you can see you passing the HTML on the subject to it And it simply adds the the subject to the Email [00:17:15](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h17m15s) The necessary places as well as the body In the necessary place Right there So that it gets send in a way that's more appropriate And then That's all happening right here Ok and that is what I'm passing in here So a custom method which gets the data from the Ajax And then sends it off [00:17:43](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h17m43s) So that's a quick tutorial on how to implement sending emails through your component Using the email helper class Obviously the email helper class Is Available on GitHub in in the component Builder And if you feel that our implementation lacks some professional Help then please do make a commit to Quest or send me an email And we'll gladly update an improved this class Although I think we are followed All the necessary standard and requirements to make it useful to everyone [00:18:26](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h18m26s) Ok thanks for watching Until next time +### Switch Global Mailer Options + +If it set to on you can decide whether you want to override the global function, the global variables. The global variables are set in your Joomla's components global area. [00:04:10](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h04m10s) + +### Joomla Global Configuration - Server + +So you would go to global configurations, and then you'd go to server, and then there's mail settings. Now these are the main or the the global settings that will be used in any component that does not add [00:04:40](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h04m40s) these settings in their config. So if you didn't create those fields and added it to your component, but you ticked the button to add the helper class to your component, that means that it will fall back to these settings in your Joomla default area. And these(Main Settings) are the values that you need to override. + +### Component Builder Email Switch Options + +If you want your [00:05:08](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h05m08s) component in some way to use other php mail or other send mail or SMTP, values that of the global, you need to set it here. That is basically what this area can do. So you use global, it falls back to the Joomla global. Otherwise you can override it on this level. And send it out in a way that is [00:05:38](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h05m38s) what you would like. + +### DKIM Settings (Encryption) + +The DKIM area is the more advanced area which allows you to encrypt and secure email sent out from you. To authenticate that it was really you that send it. This is helpful to show people that receive these emails that it's not spam, and it's really comes from you. It's more advanced. I would encourage you to read up on it. These are the values usually would be required to added a private key, a public key and these type of areas here(see video). If this is set to no, it will not be used, if it set to yes, please ensure to add the values. [00:06:25](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h06m25s) Otherwise it still will not be used. So that's basically the values that you need still to create. Component does not do this for you. You need to do it. I could possibly foresee that in the future we might add this, if you tick the helper class it adds these values for you. But even then if you have done it manually, we'll make sure that it doesn't add in twice. [00:06:51](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h06m51s) As long as these values have the same names, we will identify that, and do not add them dynamically to avoid clashes. For the meantime it's not automatically being added and so you need to do that manually if you want it to be there. If you don't, like I've said before it will fall back to the Joomla global. [00:07:15](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h07m15s) + +### Default Global In Code + +To explain to you on the code level, basically it gets from the configuration, the mailer function. Then it checks whether it's global. If it is global, then it implements Joomla's values. If it's not global, it implements your components values. [00:07:38](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h07m38s) That is basically what it will do. Now you can read through the code, but the most important area really is this(send) area. To know what is all the various options that you have in the signature to send out mail. So it's able to really send out a lot of mail but nonetheless you're also need to consider [00:08:04](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h08m04s) your servers own limitations. Since we don't want you to spam people. We do not override those values. We are simply using the Joomla default Helper jmailer. And it is been extended from another class. There are a lot of features in here. If you want to know more about them you can read up on the jmailer [00:08:35](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h08m35s) Class from Joomla. As well as read through this code here and see how we implemented it. + +### DKIM Values In Code + +These(see video) are the dkim values that you would need in your component to be able to use the dkim encryption. But you could also read up on this and check out this function here, up till there, in its way that it's implementing these features. It obviously is adding it to the mailer and most of the work is done in the mailer. [00:09:05](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h09m05s) It's basically adding the data to the mailer and the mailer takes care of the rest. Here it sends it off. + +### Error Checking For Emails In Code + +And if there is an error, let's say for some reason it didn't work out well. Then it checks whether your component helper class, your component has a helper class, it's this file here(learningmanagerhelper). [00:09:31](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h09m31s) If it have a storemessage variable or method. So if we were to go check this. You see that there is the storemessage method in the helper class. This is a custom method that I wrote. You can write it anywhere you like, but this signature should be the same. [00:10:00](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m00s) So basically this area that(learningmanager) and that(learningmanager) is dynamically updated to your component. It uses your component name here(learningmanager) and your component name there(learningmanager). But this storemessage cannot be changed, but it takes the send email, the recipient, the subject, the body, the text only, the mode and it's says that it's emailed. So you can have different types, so if you look at the method, the type can be anything. [00:10:30](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m30s) We want to do different things on different types. If it send an SMS and it didn't fail, you want to store the message. This kind of feature isn't only used when something didn't work, but also if it worked. If it was sent, it's going to store it. So it's a way to store the message,myou can [00:10:57](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m57s) let your user go, if they login, they can see messages sent to them and this kind of stuff. This is what the store message does. You will see that it's whole huge custom method that I wrote. You can update it and change it, pause the video, copy it down. If you realize this is actually something you write up yourself you just need to make sure that that part is the same. The rest is up to you how you deal with it. That is implementing the learning manager emailer [00:11:35](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h11m35s) in your component. + +### Implemented Example + +Maybe I should show you where I implemented at least in one area. I have this component called job tracking system. I open it up, you'll see that it actually has that function: Add email helper. Set it to on. The view in which we are using the email method is the job order view. Basically we want to email the client, it did a job order [00:12:21](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h12m21s) when it's created. So let me show you how I implemented it there. So here is the job order. I would basically then click on email. I can update it to whatever email I like, [00:12:45](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h12m45s) testing@vdm.io or something. Just send it in to nothing. Then once the email has been sent, it let's me know. In the top right it says email was sent successfully. That's basically what the emailer does. It just this button that sends the document [00:13:11](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h13m11s) to my client. If I want to send it to my store, the people that does the job, I could also do that here. I'm not going to explain to you the reality of taking this content, adding it to the email and sending it. That I would suspect you need to know and you need to learn or study to do that yourself. I'm simply explaining to you how to use the email helper class. + +### Above Example In Code +???? +So we will go to the code and I'll show you how I do it and [00:13:45](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h13m45s) I'll give you some pointers. but I won't go into detail About how that is done Ok so let's go to the to the code So here we are in the job order So first thing here is obviously some JavaScript So there's the send email function and Gets a set of values And then it basically gives it over to the send Email server function which sends it as a J object [00:14:20](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h14m20s) Sorry a json request to the server The send Email is the Task And when it gets a response that's when you get the notification Ok so that's Simply the JavaScript of it So now if we go to PHP Previous Tutorials we explain how to use the Ajax class I'm gonna just touched on it briefly [00:14:47](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h14m47s) You basically have your input here This is where you put set up your controller Let me show you that So you'll see in your controller There is this send email Class that's what basically was defined And this field here And you see that there is Basically three variables And they are [00:15:12](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h15m12s) Should be filtered in this way and they are fast over to these methods And you should be logged in user So if you look at the code again it basically this is the task down here it triggers the task It checks for those values and then passes it over to This method which is in the Model is a model So we go to models Ajax So here is the the model let's just scroll down to the send email So here is the send email and this again [00:15:47](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h15m47s) Is a custom Script So if I was to go back here I Close this You'd see there's the in this Ajax method is a lot I mean look at that you can see that scroll down way down is a lot of other custom methods here But this is another custom method I've written Call send mail gets the mail the HTML to type It it does the necessary Cleansing and whatever [00:16:14](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h16m14s) And then It Basically Over Here We're calling the email helper We using the send method we Passing the valuables and we Set the result in here And if the results is obviously true [00:16:38](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h16m38s) We will let the user know otherwise we give him the error ok so that That is the The short end of it I'm also using this email body to help me build the the email because I want to Make sure that it's got all the necessary HTML and stuff so you can Pause this video and type that out if you like But this is the email body that I usually use and you can see you passing the HTML on the subject to it And it simply adds the the subject to the Email [00:17:15](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h17m15s) The necessary places as well as the body In the necessary place Right there So that it gets send in a way that's more appropriate And then That's all happening right here Ok and that is what I'm passing in here So a custom method which gets the data from the Ajax And then sends it off [00:17:43](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h17m43s) So that's a quick tutorial on how to implement sending emails through your component Using the email helper class Obviously the email helper class Is Available on GitHub in in the component Builder And if you feel that our implementation lacks some professional Help then please do make a commit to Quest or send me an email And we'll gladly update an improved this class Although I think we are followed All the necessary standard and requirements to make it useful to everyone [00:18:26](https://www.youtube.com/watch?v=tp6mMUTOF2Y&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h18m26s) Ok thanks for watching Until next time