Could not instantiate mail function error (different from others)

This forum is for reporting bugs in Joomla!. Please don't report problems with extensions in here.
Forum rules
Forum Rules
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
anchal79
Joomla! Fledgling
Joomla! Fledgling
Posts: 1
Joined: Mon Dec 26, 2011 3:17 pm

Re: Could not instantiate mail function error (different fro

Post by anchal79 » Mon Dec 26, 2011 3:42 pm

I am using Yahoo web hosting and was facing the same problem. I could resolve my problem by making following changes-
1. I asked webhosting provider for SMTP Port and SMTP Host details and saved those in Global configuration.

For yahoo the details were as follows

Mailer : PHPMailer
Mailfrom : yourid@yourdomainname.com
From name : as desired
sendmail Path: /usr/sbin/sendmail
SMTP authentication: NO
SMTP security : SSL
SMTP Port : 465
SMTP Host : smtp.bizmail.yahoo.com

(leave SMTP username and PW blank)

2. In '/libraries/phpmailer/phpmailer.php

and in '/libraries/phpmailer.php/smtp.php

I changed the port from '25' to '465'

3. In 'components/com_contact/controller.php'

on 163rd line, $mail --> setSender (array($email, $name))
enter your default mail address as set in ur web hosting server as given below

$mail --> setSender( "id@urdomain.com" )


This worked perfectly for me. Hope it does for you too.

You can check it out at my website http://www.travel-india.co.in

Carole
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Mon Jan 18, 2010 6:20 am

Re: Could not instantiate mail function error (different fro

Post by Carole » Sat Mar 24, 2012 7:33 pm

after all these years, does someone have a real answer to this question?

SophiaZheng
Joomla! Fledgling
Joomla! Fledgling
Posts: 1
Joined: Fri May 04, 2012 6:38 pm

Re: Could not instantiate mail function error (different fro

Post by SophiaZheng » Fri May 04, 2012 6:44 pm

Shurick wrote:I resoved this problem by changing default smtp port from 25 to 80 in ../libraries/phpmailer/smtp.php line 30. Ask you provider what is your outgoing port.

var $SMTP_PORT = 80;

And for PHP mailer I simply installed Joomla package in other foulder and created new DB, but in this case I have problems with installation some of modules :eek:

As for the smtp, this change works. thanks too much.

srgg67
Joomla! Fledgling
Joomla! Fledgling
Posts: 4
Joined: Wed Nov 09, 2011 6:14 pm
Location: Russia
Contact:

Re: Could not instantiate mail function error (different fro

Post by srgg67 » Sat May 26, 2012 6:33 pm

Carole wrote:after all these years, does someone have a real answer to this question?
I tried to find a solution very hard and got a point where it begins (as I see it).
It starts at line (phpmailer.php):
$params = sprintf("-oi -f %s", $this->Sender);
If I remove last variable from mail() function (i.e. $params) I get message succesfully. Of course, I tried to check what $params contains. I substituted Body by $params and got a string: -oi -f srgg67@gmail.com
So I don't know why it doesn't work with $params but without it that's all right.
Hope somebody go further :)
ps. excuse my bad English :(

appearfirst
Joomla! Fledgling
Joomla! Fledgling
Posts: 1
Joined: Mon Jun 18, 2012 8:20 pm

Re: Could not instantiate mail function error (different fro

Post by appearfirst » Mon Jun 18, 2012 8:28 pm

Fixed in 30 seconds.
An old site of mie still using Joomla! version 1.5.22
My issue was completely unrelated to any Joomla settings or PHP problems. I received the error whenever the contact form was used. No mail was being sent so I searched the forums, checked my other sites, dabbled with some back-end settings, then realised my mailbox was full.
Yes, as simple as that. I was using Horde webmail in my Plesk server to forward the mail to a Gmail account. The Horde webmail box was full. Emptied the whole folder and voila - issue resolved. Not sure if that helps - hope it does for someone.

jbirkebaek
Joomla! Fledgling
Joomla! Fledgling
Posts: 2
Joined: Mon Apr 26, 2010 12:14 pm

Re: Could not instantiate mail function error (different fro

Post by jbirkebaek » Wed Sep 26, 2012 7:28 am

Hi,

Had same problem on Joomla 2.5.7

I tried to upload and overwrite the libraries folder from a Joomla 2.5.6 - NO effect.
Then I uploadet and overwrit the libraries folder from a Joomla 2.5.4 - Ta Daaa it works, I sure hope, there will be a fix in 2.5.8 ;-)

/Jeppe

Nemesiss
Joomla! Explorer
Joomla! Explorer
Posts: 295
Joined: Thu Oct 09, 2008 8:57 pm

Re: Could not instantiate mail function error (different fro

Post by Nemesiss » Thu Sep 27, 2012 4:55 am

Well, my email is not working at all and I don't' have a clue why. I have other 2.5 installs running with the same configuration and those work fine. However, the site I'm now working on gives this error and I can't figure out how to fix it. I have tried everything.

Nemesiss
Joomla! Explorer
Joomla! Explorer
Posts: 295
Joined: Thu Oct 09, 2008 8:57 pm

Re: Could not instantiate mail function error (different fro

Post by Nemesiss » Thu Oct 04, 2012 7:20 pm

My error was caused by an MX entry, if your using those you might want to check that as well.


Locked

Return to “Joomla! 1.5 Bug Reporting”