存在我看到的關於如何檢查電子郵件是否存在或不是,我不太明白如何計算器一些教程...檢查電子郵件與TELNET和PHP
方法1
基本上,我不得不在CMD.EXE運行以下命令
telnet gmail-smtp-in.l.google.com 25
helo
mail from: <[email protected]>
rcpt to: <[email protected]>
如果響應是「OK」,那麼我們有一個良好的電子郵件。我插了這一切在.BAT文件,什麼bat文件確實只是連接到遠程登錄和結束......
方法2
使用這種 http://www.geckotribe.com/php-telnet/#usage連接到遠程登錄,但我不知道我應該提供什麼樣的密碼
<?php
require_once "PHPTelnet.php";
$telnet = new PHPTelnet();
// if the first argument to Connect is blank,
// PHPTelnet will connect to the local host via 127.0.0.1
$result = $telnet->Connect('mail.gmail.com','usr','password');
if ($result == 0)
{
$telnet->DoCommand('helo', $result);
// NOTE: $result may contain newlines
echo $result;
$telnet->DoCommand('another command', $result);
echo $result;
// say Disconnect(0); to break the connection without explicitly logging out
$telnet->Disconnect();
}
?>
你們可以幫助我嗎?
我懷疑這隻適用於檢查* gmail *帳戶是否存在... – meagar 2012-02-02 21:35:25
你想檢查它是否存在?你想知道一個特定的電子郵件地址是否有效嗎?或者要知道您是否可以通過特定賬戶發送?或者是其他東西?無論哪種方式,我懷疑你的兩種方法中的任何一種都適用於Gmail,我敢肯定他們需要TLS for SMTP ... – DaveRandom 2012-02-02 21:38:40
我必須知道,如果一些用戶提供給我一個真實的電子郵件地址,而不是像fake243241addres423432243 @ yahoo .com女巫從正則的角度來看是好的,但... – Master345 2012-02-02 21:48:36