Welcome Guest, Not a member yet? Register   Sign In
Send Mail error On freebsd,sendmail
#1

[eluser]whidbey[/eluser]
I have installed sendmail in freebsd system.
my CI controler code is:
$this->email->from('[email protected]', 'whidbey');
$this->email->to('[email protected]');
$this->email->subject('Email Test');
$this->email->message('Testing the email class.');
$this->email->send();
echo $this->email->print_debugger();


I got the error:

Unable to send email using PHP mail(). Your server might not be configured to send mail using this method.

From: "whidbey"
Return-Path:


what can I do ?thank you
#2

[eluser]coolfactor[/eluser]
Based on that error message, you're not using sendmail, but rather PHP's built-in mail() function, which is the default for the Email class. You need the set the "protocol" property of your Email class to "sendmail".

Code:
$config['protocol'] = 'sendmail';
$this->email->intialize($config);
...
#3

[eluser]whidbey[/eluser]
Oh yeah,thx,It pass the message:

Your message has been successfully sent using the following protocol: sendmail

User-Agent: CodeIgniter
Date: Mon, 6 Aug 2007 09:59:46 +0800
From: "whidbey"

But I go to my mail box.I have't received it yet..
Is It really success??
#4

[eluser]coolfactor[/eluser]
When using the sendmail protocol, it's not always clear if it works properly. Make sure all parameters are set correctly (To, From, Subject, etc). You may also want to check your spam filter.
#5

[eluser]whidbey[/eluser]
how to clear it?thx..
I am not sure how to check the spam yet...
#6

[eluser]coolfactor[/eluser]
[quote author="whidbey" date="1186385111"]how to clear it?thx..
I am not sure how to check the spam yet...[/quote]

It might help to mention your native language, and someone that speaks it will be able to help you more easily.

If you're not receiving your email when using "sendmail", then you might try using "smtp" and filling in the following config parameters:
- smtp_host
- smtp_user
- smtp_pass

I've had good success using smtp to send email.
#7

[eluser]whidbey[/eluser]
I use my local freebsd server,dont have smtp user.
so I not fill smtp_user ,smtp_pass field.
I check my stmp server,it runs on 25 port ok,and
when I telnet localhost 25,
I can get the reply:
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-EXPN
250-VERB
250-8BITMIME
250-SIZE
250-DSN
250-ETRN
250-AUTH LOGIN PLAIN
250-DELIVERBY
250 HELP

so smtp server is running ok.

and my /etc/mail/access accept local access already..
so I dont know how next..

by the way,I use default charset utf-8 to send mail.

thx
#8

[eluser]whidbey[/eluser]
ok,it can send now.
but why gmail receive it as spam mail.
126.com receive it as normal mail?
thx
#9

[eluser]coolfactor[/eluser]
[quote author="whidbey" date="1186395205"]ok,it can send now.
but why gmail receive it as spam mail.
126.com receive it as normal mail?
thx[/quote]

You'll have to contact Gmail about that.
#10

[eluser]whidbey[/eluser]
thx,
but suppose any other mail like yahoo,sina,hotmail still accept it as spam mail...
need I tell them one by one?
as our users may use any kind of mailbox..

thx




Theme © iAndrew 2016 - Forum software by © MyBB