Arama butonu
Bu konudaki kullanıcılar: 1 misafir
3
Cevap
1140
Tıklama
0
Öne Çıkarma
Junk a giden otomatik mailler
H
15 yıl
Çavuş
Konu Sahibi

Arkadaşlar merhabalar,

bir sitem var php tabanlı ve buradan onay bekleyen üyelerime otomatik mail gönderiyor sistem. ancak bu otomatik mailler, kullanıcıların epostalarında "junk" a düşüyor. bunu nasıl engellerim ?

Normal olarak info@siteadı.com gibi bir adresten gönderdiğimde herhangi bir problem olmuyor. ancak otomatik giden (sistem tarafından gönderilen) mailler junka gidiyor.

bu konuda bilgi verebilecek birine ihtiyacım var.

Google Apps aracılığıyla bu sorun çözülebilir mi ?

Teşekkürler



N
15 yıl
Yarbay

Smtp ile gönderirsen inbox kısmına gelmesi çok yüksek ama bazı mail siteleri yine de junk kısmına atabiliyor. Hotmail de sorun yok ama Yahoo da var galiba örnek olarak. Hoş zaten Godaddy'nin bir çok mail bile spam kısmına düşüyor Yahoo'da.


Bu mesaja 1 cevap geldi.
Y
15 yıl
Onbaşı

Otomatik mail yollayan prosedür içerisinde mail sunucusuna bağlantını oturum açarak yaptırırsan problem düzelecektir. Sunucun üzerinde bir mail adresi oluştur ve Otomatik Mail yollayan prosedür içinde SSL veya hangi tür bağlantı çeşidi ile bağlantı sağlanıyorsa o şekilde oturum açmasını sağlatırsan problemin düzelecektir.


Bu mesaja 1 cevap geldi.
C
15 yıl
Er

Kendi kullanıdğım smtp kodum. mail() fonksiyonundan daha iyidir.

function authMail($from, $namefrom, $to, $nameto, $subject, $message, $charset = 'utf-8')
{

/* your configuration here */

$smtpServer = "mail.domain"; //ip accepted as well
$port = "25"; // should be 25 by default
$timeout = "30"; //typical timeout. try 45 for slow servers
$username = "mail adresi"; //the login for your smtp
$password = "mailinin şifresi"; //the pass for your smtp
$localhost = "127.0.0.1"; //this seems to work always
$newLine = "\r\n"; //var just for nelines in MS
$secure = 0; //change to 1 if you need a secure connect

/* you shouldn't need to mod anything else */

//connect to the host and port
$smtpConnect = fsockopen($smtpServer, $port, $errno, $errstr, $timeout);
$smtpResponse = fgets($smtpConnect, 4096);
if(empty($smtpConnect))
{
$output = "Bağlantı Kurulamadı: $smtpResponse";
return $output;
}
else
{
$logArray['connection'] = "Bağlandı: $smtpResponse";
}

//say HELO to our little friend
fputs($smtpConnect, "HELO $localhost". $newLine);
$smtpResponse = fgets($smtpConnect, 4096);
$logArray['heloresponse'] = "$smtpResponse";

//start a tls session if needed
if($secure)
{
fputs($smtpConnect, "STARTTLS". $newLine);
$smtpResponse = fgets($smtpConnect, 4096);
$logArray['tlsresponse'] = "$smtpResponse";

//you have to say HELO again after TLS is started
fputs($smtpConnect, "HELO $localhost". $newLine);
$smtpResponse = fgets($smtpConnect, 4096);
$logArray['heloresponse2'] = "$smtpResponse";
}

//request for auth login
fputs($smtpConnect,"AUTH LOGIN" . $newLine);
$smtpResponse = fgets($smtpConnect, 4096);
$logArray['authrequest'] = "$smtpResponse";

//send the username
fputs($smtpConnect, base64_encode($username) . $newLine);
$smtpResponse = fgets($smtpConnect, 4096);
$logArray['authusername'] = "$smtpResponse";

//send the password
fputs($smtpConnect, base64_encode($password) . $newLine);
$smtpResponse = fgets($smtpConnect, 4096);
$logArray['authpassword'] = "$smtpResponse";

//email from
fputs($smtpConnect, "MAIL FROM: $from" . $newLine);
$smtpResponse = fgets($smtpConnect, 4096);
$logArray['mailfromresponse'] = "$smtpResponse";

//email to
fputs($smtpConnect, "RCPT TO: $to" . $newLine);
$smtpResponse = fgets($smtpConnect, 4096);
$logArray['mailtoresponse'] = "$smtpResponse";

//the email
fputs($smtpConnect, "DATA" . $newLine);
$smtpResponse = fgets($smtpConnect, 4096);
$logArray['data1response'] = "$smtpResponse";

//construct headers
$headers = "MIME-Version: 1.0" . $newLine;
$headers .= "Content-type: text/html; charset=$charset" . $newLine;
$headers .= "To: $nameto <$to>" . $newLine;
$headers .= "From: $namefrom <$from>" . $newLine;

//observe the . after the newline, it signals the end of message
fputs($smtpConnect, "To:$to\r\n From:$from\r\nSubject:$subject\r\n$headers\r\n\r\n$message\r\n.\r\n");
$smtpResponse = fgets($smtpConnect, 4096);
$logArray['data2response'] = "$smtpResponse";

// say goodbye
fputs($smtpConnect,"QUIT" . $newLine);
$smtpResponse = fgets($smtpConnect, 4096);
$logArray['quitresponse'] = "$smtpResponse";
$logArray['quitcode'] = substr($smtpResponse,0,3);
fclose($smtpConnect);
//a return value of 221 in $retVal["quitcode"] is a success
return($logArray);
}

if(!empty($_POST)) {
$ip = $_SERVER['REMOTE_ADDR'];

$kontrol = eregi("^[A-Z0-9._%-]+@[A-Z0-9._%-]+\.[A-Z]{2,6}$", $_POST['email']);
if(empty($_POST['aciklama'])) { $gonder = 0; $mesaji = _mesaj_bos; }
if($kontrol) { $gonder = 1; } else { $mesaji = _hatali_eposta; }
if($_POST['isim'] == "") { $gonder = 0; $mesaji = _isim_bos; }

$mesaj = 'İsim : '.$_POST['isim'].'<br>';
$mesaj .= 'Telefon : '.$_POST['tel'].'<br>';
$mesaj .= 'Email : '.$_POST['email'].'<br>';
$mesaj .= 'Açıklama : '.$_POST['aciklama'].'<br><br>';
$mesaj .= 'IP : '.$ip.'<br><br>';
if($gonder == 1) {
authMail($_POST['email'], 'Web Formu', $abc_main->sitemail, 'Firma', _mail_baslik, $mesaj);
$mesaji = '<br><div align="center">'._mesaj_gitti.'</div><br>';
}
}



DH Mobil uygulaması ile devam edin. Mobil tarayıcınız ile mümkün olanların yanı sıra, birçok yeni ve faydalı özelliğe erişin. Gizle ve güncelleme çıkana kadar tekrar gösterme.