Click here to Skip to main content
Sign Up to vote bad
good
See more: PHP
I had a problem in sending email using php to squirrelMail only but i can able to send mails others like gmail,yahoo etc..I need code for this
Posted 2 Oct '12 - 20:28
Edited 2 Oct '12 - 20:29


1 solution

This has no sense at all, sending an e-mail is easy and squirrel mail is only a mail client.
It is like you would say that sending an e-mail to outlook would not be possible...
 
I'm using this PHP code to send mails and it works perfectly for me:
 
$mime_boundary=md5(time());
$headers  = "Date: ".date("l j F Y, G:i")."\n";
$headers .= "MIME-Version: 1.0\n";
$headers .= "From: your_company_name <aaa@bbb.com>\n";
$headers .= "MIME-Version: 1.0\n";
$MailContent = "asdasdasdasdasda";
$sentOK = mail("aaa@bbb.com","Subject",$MailContent,$headers);
 
Look for samples in the Internet (use google) to get more examples on how to send mails using PHP and see if the mail address used with the squirrel mail client has not been blocked in your mail server.
 
Good luck!
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Your Filters
Interested
Ignored
     
0 OriginalGriff 218
1 Sergey Alexandrovich Kryukov 159
2 Santhosh G_ 155
3 Richard MacCutchan 145
4 Maciej Los 136
0 Sergey Alexandrovich Kryukov 10,264
1 OriginalGriff 7,937
2 CPallini 4,201
3 Rohan Leuva 3,522
4 Maciej Los 3,135


Advertise | Privacy | Mobile
Web03 | 2.6.130523.1 | Last Updated 3 Oct 2012
Copyright © CodeProject, 1999-2013
All Rights Reserved. Terms of Use
Layout: fixed | fluid