Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 3 of 3
  1. #1
    Member
    Join Date
    Sep 2010
    Posts
    35

    Default SMTP -> ERROR: Failed to connect to server: Connection refused (111)

    I am having problems using PHP mailer to send emails via a websites contact form, the following error is shown - SMTP -> ERROR: Failed to connect to server: Connection refused (111)

    PHP mailer settings -
    PHP Code:
    $mail->Host       "mail.showcase-music.com"// SMTP server
      
    $mail->SMTPDebug  1;                     // enables SMTP debug information (for testing)
      
    $mail->SMTPAuth   true;                  // enable SMTP authentication
      
    $mail->Host       "mail.showcase-music.com"// sets the SMTP server
      
    $mail->Port       25;                    // set the SMTP port for the GMAIL server
      
    $mail->Username   "info@showcase-music.com"// SMTP account username
      
    $mail->Password   "*******";        // SMTP account password 
    I can send and receive emails using Outlook without issue.

    I've tried using cPanels Trace email route and it gives me the following -
    Mail Routing Error
    Filter/Alias File
    SMTP Destination
    Local Mailbox

    the email routing is auto detected as local

    I've attached a screen shot of the website's DNS settings.

    Any help would be much appreciated.
    Thanks
    Attached Thumbnails Attached Thumbnails SMTP -> ERROR: Failed to connect to server: Connection refused (111)-sc_dns.jpg  

  2. #2
    Member
    Join Date
    Sep 2010
    Posts
    35

    Default Re: SMTP -> ERROR: Failed to connect to server: Connection refused (111)

    managed to resolve this issue by setting $mail->host to localhost.

  3. #3
    Registered User
    Join Date
    May 2012
    Posts
    1
    cPanel/Enkompass Access Level

    Website Owner

    Default Re: SMTP -> ERROR: Failed to connect to server: Connection refused (111)

    Quote Originally Posted by iToke View Post
    managed to resolve this issue by setting $mail->host to localhost.
    Hi,

    Thanks a LOT !! THIS helped me to get my issue resolved

    Really I appreciate you in the way you have conducted yourself - after getting the issue resolved usually people tend to forget the post they made. You took time to post on how you got it resolved :-) Keep up the good work.

    Many Thanks,
    Nirmal Daniel

Similar Threads & Tags
Similar threads

  1. Replies: 27
    Last Post: 04-01-2009, 05:13 AM
  2. Replies: 10
    Last Post: 04-18-2005, 07:33 PM
  3. Replies: 10
    Last Post: 12-07-2004, 11:00 AM
  4. Replies: 1
    Last Post: 08-27-2004, 03:00 PM
  5. ndc: connect failed: connection refused
    By adapter in forum cPanel and WHM Discussions
    Replies: 9
    Last Post: 01-01-2004, 02:45 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube