2
Contributors
12
Replies
13
Views
4 Years
Discussion Span
Last Post by pritaeas
Featured Replies
  • 1

    Help you with what part? What do you have already? Read More

  • 1

    You can't. You can try sending a message to the address. On some servers you will get a reply that the address doesn't exists. On the other hand, some servers don't do that. Even when they do, it may still be a valid email address belonging to somebody else. You … Read More

1

Help you with what part? What do you have already?

Votes + Comments
actually i have how to send attachments to mail only. but i want to check that mail id is correct or not, and i dont know what process to do...
0

actually i have how to send attachments to mail only.
but i want to check that mail id is correct or not, and i dont know what process to do...

0
$strTo = $_POST["txtTo"];
$strSubject = $_POST["txtSubject"];
$strMessage = nl2br($_POST["txtDescription"]);


$strSid = md5(uniqid(time()));

$strHeader = "";
$strHeader .= "From: ".$_POST["txtFormName"]."<".$_POST["txtFormEmail"].">\nReply-To: ".$_POST["txtFormEmail"]."";

$strHeader .= "MIME-Version: 1.0\n";
$strHeader .= "Content-Type: multipart/mixed; boundary=\"".$strSid."\"\n\n";
$strHeader .= "This is a multi-part message in MIME format.\n";

$strHeader .= "--".$strSid."\n";
$strHeader .= "Content-type: text/html; charset=utf-8\n";
$strHeader .= "Content-Transfer-Encoding: 7bit\n\n";
$strHeader .= $strMessage."\n\n";


if($_FILES["fileAttach"]["name"] != "")
{
    $strFilesName = $_FILES["fileAttach"]["name"];
    $strContent = chunk_split(base64_encode(file_get_contents($_FILES["fileAttach"]["tmp_name"]))); 
    $strHeader .= "--".$strSid."\n";
    $strHeader .= "Content-Type: application/octet-stream; name=\"".$strFilesName."\"\n"; 
    $strHeader .= "Content-Transfer-Encoding: base64\n";
    $strHeader .= "Content-Disposition: attachment; filename=\"".$strFilesName."\"\n\n";
    $strHeader .= $strContent."\n\n";
}


$flgSend = @mail($strTo,$strSubject,null,$strHeader);  

if($flgSend)
{
    echo "Mail successfully sent.";
}
else
{
    echo "Cannot send mail.";
}
0

from the above code i am uploading my resume and sending to mail, but here i want to check that mail id is valid or not so how can i do that ?

0

created text boxes in html pages as
1)to mail id:_______
2)from mail id:______
3)upload file:
4) submit.
here am giving to_mail_id as my mail_id and from_mail_id as abc@xyz.com
but am receiving mail from abc@xyz.com
but i want to check the from_mail_id is correct or wrong

Edited by ratanji

0

i dont know the way how to check the mail, so if u know the solution please can you help me ?

0

sorry that is checking whether the format is correct or not only.
but i want to check the mail id is original or not...
for example pritaeas@gmail.com is your mail_id and pritaeas@google.com is fake_id...so how to find like which is original_id and which is fake_id??

1

You can't. You can try sending a message to the address. On some servers you will get a reply that the address doesn't exists. On the other hand, some servers don't do that. Even when they do, it may still be a valid email address belonging to somebody else. You cannot distinguish between those.

Votes + Comments
thanQ Pritaeas
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.