phpmailer and gmail BŁĄD SMTP: Nie można połączyć się z serwerem: Sieć jest nieosiągalna (101) Połączenie SMTP nie powiodło się

Potrzebuję pomocy, proszę, to mój kod:

require 'PHPMailerAutoload.php';
$mail = new PHPMailer;
$mail->isSMTP();
$mail->Host = "smtp.gmail.com";
$mail->SMTPDebug = 2;
$mail->SMTPAuth = true;

$mail->SMTPSecure = "tls";
$mail->Port = 587;

$mail->Username = '[email protected]';
$mail->Password = 'somepass';
$mail->addAddress('[email protected]', 'Josh Adams');
$mail->Subject = 'PHPMailer GMail SMTP test';
$body = 'This is the HTML message body in bold!';
$mail->MsgHTML($body);
if (!$mail->send()) {
    echo "Mailer Error: " . $mail->ErrorInfo;
} else {
    echo "Message sent!";
}

i otrzymuję ten błąd:2013-12-11 15:15:02 BŁĄD SMTP: Nie można połączyć się z serwerem: Sieć jest nieosiągalna (101) Połączenie SMTP nie powiodło się. Błąd Mailer: SMTP connect () nie powiódł się.

proszę o pomoc?

questionAnswers(2)

yourAnswerToTheQuestion