in mynew php web app, i am going to provide a link : 'forgot password' and my php code is going to email the password using the email address on file.
my app is using the zend framework, and i am following this config
$smtpServer = 'mail.mtmphp.x10hosting.com';
$username = 'manoogim@mtmphp.x10hosting.com';
$password = 'zzzzzz';
$config = array('ssl' => 'tls',
'auth' => 'login',
'username' => $username,
'password' => $password);
$transport = new Zend_Mail_Transport_Smtp($smtpServer, $config);
$mail = new Zend_Mail();
$mail->setFrom('sender@example.com', 'Some Sender');
$mail->addTo('manoogim@yahoo.com', 'Some Recipient');
$mail->setSubject('Test Subject');
$mail->setBodyText('This is the text of the mail.');
$mail->send($transport);
my approach is to first develop and test the web app on my local desktop, and then i will upload it to x10hosting. (i have not decided yet if i will continue with free hosting, or get a paid account as soon as ready to go live.)
i created an email account on x10hosting named manoogim@mtmphp.x10hosting.com.
when i run the above code, i get this error:
Message: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
and here is the top of the stack:
0 C:\Program Files\Zend\Apache2\htdocs\zend-shows\library\Zend\Mail\Protocol\Smtp.php(167): Zend_Mail_Protocol_Abstract->_connect('tcp://mail.mtmp...')
#1 C:\Program Files\Zend\Apache2\htdocs\zend-shows\library\Zend\Mail\Transport\Smtp.php(195): Zend_Mail_Protocol_Smtp->connect()
#2 C:\Program Files\Zend\Apache2\htdocs\zend-shows\library\Zend\Mail\Transport\Abstract.php(348): Zend_Mail_Transport_Smtp->_sendMail()
also i tried $username='manoogim+mtmphp.x10hosting.com' but that gave the same error.
anyone has ideas why am i getting the connection error. thanks in advance!
my app is using the zend framework, and i am following this config
$smtpServer = 'mail.mtmphp.x10hosting.com';
$username = 'manoogim@mtmphp.x10hosting.com';
$password = 'zzzzzz';
$config = array('ssl' => 'tls',
'auth' => 'login',
'username' => $username,
'password' => $password);
$transport = new Zend_Mail_Transport_Smtp($smtpServer, $config);
$mail = new Zend_Mail();
$mail->setFrom('sender@example.com', 'Some Sender');
$mail->addTo('manoogim@yahoo.com', 'Some Recipient');
$mail->setSubject('Test Subject');
$mail->setBodyText('This is the text of the mail.');
$mail->send($transport);
my approach is to first develop and test the web app on my local desktop, and then i will upload it to x10hosting. (i have not decided yet if i will continue with free hosting, or get a paid account as soon as ready to go live.)
i created an email account on x10hosting named manoogim@mtmphp.x10hosting.com.
when i run the above code, i get this error:
Message: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
and here is the top of the stack:
0 C:\Program Files\Zend\Apache2\htdocs\zend-shows\library\Zend\Mail\Protocol\Smtp.php(167): Zend_Mail_Protocol_Abstract->_connect('tcp://mail.mtmp...')
#1 C:\Program Files\Zend\Apache2\htdocs\zend-shows\library\Zend\Mail\Transport\Smtp.php(195): Zend_Mail_Protocol_Smtp->connect()
#2 C:\Program Files\Zend\Apache2\htdocs\zend-shows\library\Zend\Mail\Transport\Abstract.php(348): Zend_Mail_Transport_Smtp->_sendMail()
also i tried $username='manoogim+mtmphp.x10hosting.com' but that gave the same error.
anyone has ideas why am i getting the connection error. thanks in advance!