Menu

Call to undefined method SMTP::getError

Help
TonyMJ
2011-11-20
2013-05-30
  • TonyMJ

    TonyMJ - 2011-11-20

    Hi,
    My host has disabled the PHP mail() function, so I'm trying to use SMTP t send mail. I thought I had it set up correctly, but it crashes out with this fatal error. The class in class.smtp.php doesn't contain a function called getError. Any suggestions please.
    Also, can I use 'localhost' as the smtp server? my smtp mailer is mail.
    Tony

     
  • Gerry Kroll

    Gerry Kroll - 2011-11-20

    You will need to ask your hosting service provider for help.

    The problem could be that your local PC is using a different Internet service provider from that used by your hosting company. 

    If you're using the SMTP credentials that work for your local PC on the hosting provider's network, the attempt could fail.  That's because many ISPs refuse to honour SMTP requests that don't originate from within their own network.

     
  • TonyMJ

    TonyMJ - 2011-11-20

    After some digging, I found that the version of class.smtp.php provided with Phpgedview is a bit out of date and doesn't contain the function getError. I replaced it with a more up to date version and that's now fixed. However, may attempts to send mail externaly still fail at the SMTP authorisation stage. I tried a simple script that sends mail with SMTP authorisation and that works fine, so it's something in the classes provided with phpgedview. Baffling!

     

Log in to post a comment.