News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

How to disable registration mail?

Started by Twototango, December 06, 2018, 13:17:43 PM

Previous topic - Next topic

Twototango

I want to stop VM sending out the registration mail to new users.

Registration mail to shop owner is ok
But do not want new users to receive this.

How do I go about this, can't see an option for it in VM (3.4.2)

Thanks for replying

GJC Web Design

Hi  Jack,

it is hardcoded in the administrator\components\com_virtuemart\models\user.php ->  private function sendRegistrationEmail($user,$password, $useractivation);

you could adapt it there  - a switch in admin could be nice though
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

Twototango

Thanks John, I should be able to find that ;-)

I agree... shop owners should have control over what is, and isn't, send to their customers.
A switch would be nice.



Guntchaa

Guys, my expertise in php is very weak, may be you can post here code snippet for canceling sending registration information to shopper?
This will be very helpful for me and others.
(Yes, i understand, changes will be lost after update ...)

GJC Web Design

Haven't tested but probably just comment out the function call

administrator\components\com_virtuemart\models\user.php  ~ line 383

end of the register function


// $this->sendRegistrationEmail($user,$pw, $useractivation);
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

Guntchaa

(J! 3.9.18; VM 3.6.10)
// $this->sendRegistrationEmail($user,$pw, $useractivation);

should be, but not working ... Shopper still receive registration emails ... any other ideas?

I commented out all block (lines 287-398) - the same.

Jörgen

#6
Using overrides in your template?
May also search for the function Call in all your Joomla files.
Jörgen @ Kreativ Fotografi
Joomla 3.9.18
Virtuemart 3.4.x
Olympiantheme Hera (customized)
This reflects current status when viewing old post.

Guntchaa

As i see, generally the solution mentioned there before - works.

As I see, my problem is located in plg_VPOnePageCheckout_VM3-6.8.zip.
When VPOPC is disabled, shopper do not receive registration email.

But, as i see, vpopc is written in JS, i have no idea how to deal with this.

pinochico

Then you can try another forum, especially for VPOnePageCheckout
www.minijoomla.org  - new portal for Joomla!, Virtuemart and other extensions
XML Easy Feeder - feeds for FB, GMC,.. from products, categories, orders, users, articles, acymailing subscribers and database table
Virtuemart Email Manager - customs email templates
Import products for Virtuemart - from CSV and XML
Rich Snippets - Google Structured Data
VirtueMart Products Extended - Slider with products, show Others bought, Products by CF ID and others filtering products

jenkinhill

Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

Guntchaa

The correct solution is (thank you to Jumbo from VP forum):
components/com_virtuemart/helpers/shopfunctionsf.php
static public function renderMail ($viewName, $recipient, $vars = array(), $controllerName = NULL, $noVendorMail = FALSE,$useDefault=true)

replace
$user = self::sendVmMail( $view, $recipient, $noVendorMail );

with
// Do not send registration mails to users
if($viewName != 'user') {
$user = self::sendVmMail( $view, $recipient, $noVendorMail );
}

pinochico

I don't understand why when I buy on the e-shop, I don't get my account information so that I can't log in next time (I don't know my username and password).

Is this a requirement?

Remember that this hack will disappear the next time you upgrade VirtueMart.
www.minijoomla.org  - new portal for Joomla!, Virtuemart and other extensions
XML Easy Feeder - feeds for FB, GMC,.. from products, categories, orders, users, articles, acymailing subscribers and database table
Virtuemart Email Manager - customs email templates
Import products for Virtuemart - from CSV and XML
Rich Snippets - Google Structured Data
VirtueMart Products Extended - Slider with products, show Others bought, Products by CF ID and others filtering products