Just helping someone with their Opencart site but we are banging our heads against the wall when it comes to getting the emails working,,. Anyone have any ideas of what to try?
I have my own OC 2.1.0.2 store with emails setup and working fine using SMTP... no problems at all with my store. The store I am currently helping with is also OC 2.1.0.2 but even with the exact same SMTP settings no order emails go through...
Have tried the "Mail" setting with my gmail address earlier today and it worked, try his gmail address with "Mail" setting and no luck... then tried mine again just to test something and again no luck with mine now.
Have also contacted the hosting provider, all is well at their end and they have confirmed port 25 is open.
Also tried removing all extensions installed just in case but this made no difference.. basically have tried multiple gmail accounts, a hotmail account and proper domain email all with no luck except my gmail once but now nothing.
Why would his store not work even when using exact settings as mine and my store works fine? His setup is pretty much identical to mine so not sure what the problem could be...
Also made sure all admin settings were set to "yes" to make sure all emails are sent. Contact form seems to work with gmail addresses but not order emails.
Any help or ideas would be very much appreciated.
Cheers
Norman in 't Veldt
Moderator OpenCart Forums
_________________ READ and Search BEFORE POSTING _________________
Our FREE search: Find your answer FAST!.
[How to] BTW + Verzend + betaal setup.
No disrespect meant. Easier to put a google url like that
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
What I have found today...
12.45pm placed test order received both emails (admin and customer copies)
12.46pm placed test order received only admin copy
12.47pm placed test order received only customer copy
All have different order numbers and nothing was changed between the 3 test orders but still having issues. Nothing in the error logs or anything to try and track what the problem may be...
Any ideas would be much appreciated
Cheers
It looks like since you applied the same strategy to receive your emails in a constant way, it may be possible that your server tracks the short-time notice. Even dedicated servers may require to initiate chronologic tasks in order to receive emails between different time range rather than constant to avoid email filtering to track your emails synchronously.impairedspook wrote:Ok update... last night all seemed to be working well for about 5 test orders. However this morning we have issues again..
What I have found today...
12.45pm placed test order received both emails (admin and customer copies)
12.46pm placed test order received only admin copy
12.47pm placed test order received only customer copy
All have different order numbers and nothing was changed between the 3 test orders but still having issues. Nothing in the error logs or anything to try and track what the problem may be...
Any ideas would be much appreciated
Cheers
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
Any ideas will be greatly appreciated - hoping something will point me in the right direction as I have tried everything I can think of to get this working.
Cheers
In all mail function calls:
change setFrom to
Code: Select all
$mail->setFrom($this->config->get('config_email'));
Code: Select all
$mail->setReplyTo($this->request->post['email']);
I have the above for all my OC's
Reason: Added code tags.
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
Also update.. all emails seem to be working except admin and customer order emails... have tested out new customer, contact form, forgotten password, admin email and newsletter and all have worked except the most important ones...
Appreciate the help.
Cheers
model/checkout/order.php -> addOrderHistory
controller/information/contact.php
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
Thanks, in model/checkout/order.php..
Code: Select all
$mail->setFrom($this->config->get('config_email'));
Code: Select all
$mail->setFrom($this->request->post['email']);
Code: Select all
$mail->setFrom($this->config->get('config_email'));
but still had no luck receiving order emails..
Cheers
Reason: Added code tags.
What does it indicate in your error logs after making the changes?impairedspook wrote:Hi artcore,
Thanks, in model/checkout/order.php.. $mail->setFrom($this->config->get('config_email')); already exists but in controller/information/contact.php I replaced $mail->setFrom($this->request->post['email']); with $mail->setFrom($this->config->get('config_email')); but still had no luck receiving order emails..
Cheers
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
Create a simple mail script in site root mailtest.php and use it to test
-f switch on sender email
with and without space after -f
Test with store mail sender, external email also.
and add this also to the top of it:
Code: Select all
ini_set('display_startup_errors',1);
ini_set('display_errors',1);
error_reporting(-1);
https://www.conetix.com.au/support/arti ... -mail-test
There must be something that gives you a clue after this.
You can also try to use smtp of course
Reason: Added code tags.
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
Thank you very much for the replies and help.. I think I might be sorted now (Fingers crossed) I have placed 6 test orders this morning and have received both the admin and customer order emails...
It seems it may of been just working out the host settings etc.. Once I was given access to the hosting plan I could then start playing around and trying to get the right port details etc.
For anyone else that may have issues.. Hosting is provided by Bluehost and the settings that seem to be working are...
- Under the "Store" tab make sure email is set to "youremail@yourdomain.com"
- Under the "Mail" tab..
Was a bit of a strange setup... past stores I have either used "mail" and the entered "-fyouremail@yourdomain" as the mail protocol or filled out all the details and used "SMTP". Never had to set it up like this before...Mail protocol: Mail
Mail parameters:
SMTP Hostname: mail.yourdomain.com
SMTP USername: youremail@yourdomain.com
SMTP Port: 26
SMTP Timeout: 5
Really appreciate the help and hopefully all should go well now
Cheers
Reason: Added quote tags.
Ok still not quite right... the store will send both admin and customer emails if I entered both email addresses as example@mydomain.com however if I change admin email to something else but leave customers as example@mydomain.com I receive only the customer copy. Leave admin as example@mydomain.com but change customers to something different then I receive only the admin email not the customers one.
What could cause the problem? Seems there is no issue with OC sending emails weather it be the admin or customer copies but just seems to not like having 2 different addresses... Or will only send emails to @mydomain.com...
If I setup both customer and admin emails the same but have an additional gmail address I will receive all 3 copies but change customer or admin email then even the additional email won't come through..
For the life of me I can't figure out what's going wrong...
It does not seem like there are problems with OC sending emails because why would it work when both emails are the same... Again any help will be greatly appreciated.
Users browsing this forum: No registered users and 37 guests