[Skip to main content](#vessel-content)

#   send mail when activate the new vendor account

##

- **[zetap](/forum/user/44792-zetap "View zetap's Profile")**
- [![zetap's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/44792-zetap "View zetap's Profile") Topic Author
- [ Offline](/forum/user/44792-zetap)

Less More

- Posts: 127
- Thank you received: 3
-
-

10 years 1 month ago [\#251683](#251683) by [zetap](/forum/user/44792-zetap "View zetap's Profile")  *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#251683 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")* was created by *[zetap](/forum/user/44792-zetap "View zetap's Profile")*

-- HikaShop version -- : hikashop_business_v2.6.4
-- HikaMarket version -- : hikamarket_multivendor_v1.7.1
-- Joomla version -- : 3.6.2

Hello

In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?

Thank you !

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26401
- Thank you received: 4081
-
- [](http://obsi.dev)
-

10 years 1 month ago [\#251685](#251685) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#251685 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hi,

The best would be to send an email when the vendor is saved (from unpublished to published).
So in the HikaMarket vendor class (admin/comp/com_hikamarket/classes/vendor.php), in the function "save", just before the end and the call of the trigger "onAfterVendorCreate / onAfterVendorUpdate", you can add some code Code:

// For manual validation ; the vendor is notified when his account is published. // Note: An email will be send each time the vendor is being published, not only the first time. // if(!$new &amp;&amp; (int)$config-&gt;get('allow_registration', 0) == 1 &amp;&amp; empty($vendor-&gt;old-&gt;vendor_published) &amp;&amp; !empty($vendor-&gt;vendor_published)) { $user_id = (isset($vendor-&gt;vendor_admin_id) ? (int)$vendor-&gt;vendor_admin_id : (int)$vendor-&gt;old-&gt;vendor_admin_id); $userClass = hikamarket::get('shop.class.user'); $shopuser = $userClass-&gt;get($user_id); $mailClass = hikamarket::get('shop.class.mail'); $mailClass-&gt;mail_folder = HIKAMARKET_MEDIA . 'mail' . DS; $infos = new stdClass; $infos-&gt;vendor =&amp; $vendor; $infos-&gt;vendor_name = $vendor-&gt;vendor_name; $infos-&gt;user =&amp; $shopuser; $mail = $mailClass-&gt;get('market.vendor_registration', $infos); if(!empty($mail)) { $mail-&gt;subject = JText::sprintf($mail-&gt;subject, HIKASHOP_LIVE); $mail-&gt;from_name = $shopConfig-&gt;get('from_name'); $mail-&gt;from_email = $shopConfig-&gt;get('from_email'); $mail-&gt;dst_email = (!empty($infos-&gt;email)) ? $infos-&gt;email : $vendor-&gt;vendor_email; $mail-&gt;dst_name = (!empty($infos-&gt;name)) ? $infos-&gt;name : $vendor-&gt;vendor_name; if(!empty($mail-&gt;dst_email)) $mailClass-&gt;sendMail($mail); } }

Afterwards you should modify a little the email "vendor registration" in order to display specific text if the vendor is created or if he is being published.
You can read the configuration setting "allow_registration" to check if the manual validation is enable or not ; and you can also check the vendor_published state (and the old-&gt;vendor_published one too).

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[zetap](/forum/user/44792-zetap "View zetap's Profile")**
- [![zetap's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/44792-zetap "View zetap's Profile") Topic Author
- [ Offline](/forum/user/44792-zetap)

Less More

- Posts: 127
- Thank you received: 3
-
-

10 years 1 month ago [\#251794](#251794) by [zetap](/forum/user/44792-zetap "View zetap's Profile")  Replied by *[zetap](/forum/user/44792-zetap "View zetap's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#251794 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hi, thanks for your response

well, in the mail code "vendor registration", I must add a conditional to know if $ vendor-&gt; vendor_published is 1 or 0 and the according to the condition, the text of the mail, is that correct?

Regards !

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26401
- Thank you received: 4081
-
- [](http://obsi.dev)
-

10 years 1 month ago [\#251795](#251795) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#251795 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hi,

Right.
With " $vendor-&gt;vendor_published " ( 0 or 1 ) you can know if the vendor is currently published or not.
And with " $vendor-&gt;old-&gt;vendor_published " you can know if the vendor was previously published or not.

So with Code:

if($vendor-&gt;old-&gt;vendor_published == 0 &amp;&amp; $vendor-&gt;vendor_published == 1) { /* ... */ }

You know that the vendor is being published.
If you do not have a " $vendor-&gt;old " you know that the vendor is being created.

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

The following user(s) said Thank You: [zetap](/forum/user/44792-zetap "View zetap's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[zetap](/forum/user/44792-zetap "View zetap's Profile")**
- [![zetap's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/44792-zetap "View zetap's Profile") Topic Author
- [ Offline](/forum/user/44792-zetap)

Less More

- Posts: 127
- Thank you received: 3
-
-

10 years 1 month ago -  10 years 1 month ago [\#251864](#251864) by [zetap](/forum/user/44792-zetap "View zetap's Profile")  Replied by *[zetap](/forum/user/44792-zetap "View zetap's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#251864 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hello

Perfect I understand.

Now, I'm not clear where paste the code you sent me earlier, you said should go in fiunción "save" in "admin/comp/com_hikamarket/classes/vendor.php" just before the end and the call of the trigger "onAfterVendorCreate / onAfterVendorUpdate"
I have tried paste before the call of the trigger, after the call of the trigger, before "return $status" after "return $status", but does not send the email after recording the seller from unpublished to published, you can tell me in the code that I copy you, where you add the code to send the email?
Code:

public function save(&amp;$vendor) { /*....*/ } } /*Insert the code right here */ if($new) { $dispatcher-&gt;trigger('onAfterVendorCreate', array(&amp;$vendor)); } else { $dispatcher-&gt;trigger('onAfterVendorUpdate', array(&amp;$vendor)); } } return $status; }

thanks greetings !

Last edit: 10 years 1 month ago by [Jerome](/forum/user/80-jerome "View Jerome's Profile"). Reason: cleaning code

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26401
- Thank you received: 4081
-
- [](http://obsi.dev)
-

10 years 1 month ago [\#251869](#251869) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#251869 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hi,

I have edited your message to give you the indication where to paste the code I gave you before.

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[zetap](/forum/user/44792-zetap "View zetap's Profile")**
- [![zetap's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/44792-zetap "View zetap's Profile") Topic Author
- [ Offline](/forum/user/44792-zetap)

Less More

- Posts: 127
- Thank you received: 3
-
-

10 years 1 month ago [\#252086](#252086) by [zetap](/forum/user/44792-zetap "View zetap's Profile")  Replied by *[zetap](/forum/user/44792-zetap "View zetap's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#252086 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hi, thanks for your response

I paste the code where you indicated to me, but it did not work, after editing "vendor.php" I registered a new seller, then from the backend, I save the seller from unpublished to published and has not sent the mail notification.

that I may be doing wrong?

Thank you very much !

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26401
- Thank you received: 4081
-
- [](http://obsi.dev)
-

10 years 1 month ago [\#252143](#252143) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#252143 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hi,

I am not able to reproduce your issue.
If I unpublish/publish a vendor in the backend, thanks to the "toogle" in the vendor listing or directly in the vendor page ; the notification email is sent to my vendor email.

Please note that the email is send only when the vendor registration is "manual validation", that your vendor need a "vendor email" and the email "Market: vendor registration" need to be published.
Please also note that the first time the vendor is registering, the email should also be sent.
If you made some override in the email ; please backup and revert them.

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[zetap](/forum/user/44792-zetap "View zetap's Profile")**
- [![zetap's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/44792-zetap "View zetap's Profile") Topic Author
- [ Offline](/forum/user/44792-zetap)

Less More

- Posts: 127
- Thank you received: 3
-
-

10 years 1 month ago -  10 years 1 month ago [\#252151](#252151) by [zetap](/forum/user/44792-zetap "View zetap's Profile")  Replied by *[zetap](/forum/user/44792-zetap "View zetap's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#252151 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hello

I followed all your instructions, I do not understand why it does not work.
I have verified that the vendor that I want to activate, he has configured a "email vendor", when the new seller is registered, the email is sent correctly, but when upgrading unpublish / publish, email is not sent.
I attached screenshot hihamarket settings, mail code, which have not changed, and the class code vendor.php with the modifications you provided me.
I appreciate your help to solve this problem.

Regards !

- [ ![email&#95;anda&#95;registration&#95;options.jpg](/forum/attachment/33909) ](/forum/attachment/33909 "...on&#95;options.jpg") [ ](/forum/attachment/33909?download=1 "...on&#95;options.jpg")

Last edit: 10 years 1 month ago by [Jerome](/forum/user/80-jerome "View Jerome's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26401
- Thank you received: 4081
-
- [](http://obsi.dev)
-

10 years 1 month ago [\#252171](#252171) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#252171 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hi,

Please do not include files from HikaShop or HikaMarket in the forum.
I see that you do not have HikaShop 1.7.2 ; I have exceptionnaly update the package in order to add the patch for the vendor notification.
Please update to the latest version.
[ www.hikashop.com/support/documentation/1...arket-changelog.html](https://www.hikashop.com/support/documentation/147-hikamarket-changelog.html)

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

The following user(s) said Thank You: [zetap](/forum/user/44792-zetap "View zetap's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[zetap](/forum/user/44792-zetap "View zetap's Profile")**
- [![zetap's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/44792-zetap "View zetap's Profile") Topic Author
- [ Offline](/forum/user/44792-zetap)

Less More

- Posts: 127
- Thank you received: 3
-
-

10 years 1 month ago [\#252300](#252300) by [zetap](/forum/user/44792-zetap "View zetap's Profile")  Replied by *[zetap](/forum/user/44792-zetap "View zetap's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#252300 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hi, thanks for your response

Fortunately, with your help, I was able to resolve the issue of mail when activating the seller.

Greetings thank you !

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[zetap](/forum/user/44792-zetap "View zetap's Profile")**
- [![zetap's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/44792-zetap "View zetap's Profile") Topic Author
- [ Offline](/forum/user/44792-zetap)

Less More

- Posts: 127
- Thank you received: 3
-
-

10 years 1 month ago -  10 years 1 month ago [\#252793](#252793) by [zetap](/forum/user/44792-zetap "View zetap's Profile")  Replied by *[zetap](/forum/user/44792-zetap "View zetap's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#252793 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hello

I return to the post because I desafortundamente noticed that I thought solved, not working properly.

you indicated me to use the following code in the mail "Market: Vendor registration"
Code:

if ($ vendor-&gt; old-&gt; == 0 &amp;&amp; $ vendor_published vendor-&gt; vendor_published == 1) {/ * ... * /}

Well,I add to conditional, a "else", to send the appropriate text according to whether it was vendor register or vendor activation
Code:

&lt;? Php if ($ vendor-&gt; old-&gt; == 0 &amp;&amp; $ vendor_published vendor-&gt; vendor_published == 1) {?&gt; / * Registered seller * / {TXT: VENDOR_REGISTRATION_BEGIN_MESSAGE} &lt;? Php} else {?&gt; / * Seller activated * / {TXT: VENDOR_REGISTRATION_ACTIVE_MESSAGE} &lt;? Php}?&gt;

The problem is, that always the option going for the "else", whether vendor registration or change unpublish / publish vendor.
I can indicate that I should change in the condition to do the right thing.

Thank you !

Last edit: 10 years 1 month ago by [zetap](/forum/user/44792-zetap "View zetap's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26401
- Thank you received: 4081
-
- [](http://obsi.dev)
-

10 years 1 month ago [\#252797](#252797) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#252797 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hi,

The code I gave you is : Code:

if($vendor-&gt;old-&gt;vendor_published == 0 &amp;&amp; $vendor-&gt;vendor_published == 1) { /* ... */ }

It comes from the patch for the HikaMarket class I gave you before.

The code you paste is really different and does not sound like something valid.

Now, if you put that code directly in the HTML part ; you won't have a variable " $vendor " but you will have it under " $data-&gt;vendor ".
So that code Code:

if($data-&gt;vendor-&gt;old-&gt;vendor_published == 0 &amp;&amp; $data-&gt;vendor-&gt;vendor_published == 1) { /* ... */ }

will be more appropriate for the email content.

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[zetap](/forum/user/44792-zetap "View zetap's Profile")**
- [![zetap's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/44792-zetap "View zetap's Profile") Topic Author
- [ Offline](/forum/user/44792-zetap)

Less More

- Posts: 127
- Thank you received: 3
-
-

10 years 1 month ago [\#252829](#252829) by [zetap](/forum/user/44792-zetap "View zetap's Profile")  Replied by *[zetap](/forum/user/44792-zetap "View zetap's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#252829 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hello, thanks for the answer

According to what I indicas, replace
Code:

if ($ vendor-&gt; old-&gt; == 0 &amp;&amp; $ vendor_published vendor-&gt; vendor_published == 1)

by Code:

if ($ data-&gt; vendor-&gt; old-&gt; == 0 &amp;&amp; vendor_published $ data-&gt; vendor-&gt; vendor_published == 1)

But continues out by the refusal of the conditional, no matter if is the record of the seller or is vendor state change unpublished/published

To check the values ​​of variables in both situations add the following code, prior to conditional Code:

&lt;P&gt; &lt;? Php echo $ data-&gt; vendor-&gt; old-&gt; vendor_published; ?&gt; - Old vendor &lt;/ p&gt; &lt;P&gt; &lt;? Php echo $ data-&gt; vendor-&gt; vendor_published; ?&gt; - Vendor &lt;/ p&gt;

Result when vendor registers
Code:

- $ Data-&gt; vendor-&gt; old-&gt; vendor_published = no value - $ Data-&gt; vendor-&gt; vendor_published = no value

Result after change vendor state, unpublished/published Code:

- $ Data-&gt; vendor-&gt; old-&gt; vendor_published = 0 - $ Data-&gt; vendor-&gt; vendor_published = 1

With the values of the variables will always go for refusal conditional.

You could tell me how I can fix it?

Thank you very much !

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26401
- Thank you received: 4081
-
- [](http://obsi.dev)
-

10 years 4 weeks ago [\#252830](#252830) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#252830 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hi,

You should really check the code you paste ; it's not what I gave you and it's not a something valid in PHP...

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[zetap](/forum/user/44792-zetap "View zetap's Profile")**
- [![zetap's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/44792-zetap "View zetap's Profile") Topic Author
- [ Offline](/forum/user/44792-zetap)

Less More

- Posts: 127
- Thank you received: 3
-
-

10 years 4 weeks ago [\#252956](#252956) by [zetap](/forum/user/44792-zetap "View zetap's Profile")  Replied by *[zetap](/forum/user/44792-zetap "View zetap's Profile")* on topic *[send mail when activate the new vendor account](/forum/23-market-how-to/886779-send-mail-when-activate-the-new-vendor-account#252956 "-- HikaShop version -- : hikashop&#95;business&#95;v2.6.4 -- HikaMarket version -- : hikamarket&#95;multivendor&#95;v1.7.1 -- Joomla version -- : 3.6.2  Hello  In hikamarket you can configure that the logging of new sellers either manually validated by the site administrator, the system will send an email when to the new vendor you register as such, but the system will not send an email when to the new vendor it is validated by the site administrator, how I can do to make the vendor receives an email when the administrator activate the new vendor account?  Thank you !")*

Hello

Well, I've already solved, now commands the same mail with different text according to action.

Thanks greetings !

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzIzLW1hcmtldC1ob3ctdG8vODg2Nzc5LXNlbmQtbWFpbC13aGVuLWFjdGl2YXRlLXRoZS1uZXctdmVuZG9yLWFjY291bnQ/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

Moderators: [Obsidev](/forum/user/7040-obsidev "View Obsidev's Profile")

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.135 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
