Sorry if this is a stupid question, but are you using PHP5 or higher? If you aren’t, you won’t be able to use any classes at all as they weren’t introduced until version 5 of PHP.
By default Method to send mail in PHPMailer is set to mail() function. If this mail() function is disabled then it gives that error.
So please check on your server if that mail function works correctly(without PHPMailer).
I guess this is because your smtp configuration is not properly being received to class.smtp.php:
I found somewhere in the internet pages:
sounds like your sendmail isn’t working, assuming linux, or smtp if windows. That error occurs trying to use the ‘mail’ built-in php mail() codepath, if the mail function fails. could also be that your php isn’t properly configured for mail(). Oh, and the “language string” thing means that it was unable to load the language files. maybe a folder changed? or phpmailer isn’t in the same path?
Generally stuff like this happens when SOMETHING changes on your system. A service isn’t running that should be, you upgraded something, etc. PHP version change, php INI options changed, sendmail or SMTP service change (depending on linux vs windows)… This stuff really doesn’t just stop working. I assume you’ve rebooted?
But everything if fine with the system.Also I have tried with php’s mail() function and it is working properly.
the example I have given above is one of the example from phpmailer downloads.
But, I am not getting what’s wrong with the code or where I have to made changes.
Also smtp is configured…
Please help me out?
Since this is not the usual error as far as i know, so please try to get help from your best friend GOOGLE with the same error message as keyword. It must point you to a helpful direction I hope.