Welcome Guest, Not a member yet? Register   Sign In
email to hotmail
#1

[eluser]alrightythen[/eluser]
Hi

Does someone know how to make a mail that's sent with codeigniter pass the security of hotmail? Everytime I send a mail it goes right into junk mail.

I've read some change in headers could solve the problem but it didn't work.

Here's my code..
Code:
$this->load->library('email');
$config['protocol'] = 'sendmail';
$config['mailpath'] = '/usr/sbin/sendmail';
$config['charset'] = 'iso-8859-1';
$config['wordwrap'] = TRUE;
            
$this->email->initialize($config);
$this->email->set_newline("\r\n");

/*   E-MAIL HEADER   */
$this->email->set_alt_message(    'From: [email protected]'."\r\n".
                                'X-Mailer: PHP/'.phpversion()   );

$this->email->from($this->input->post('E-mail'), $this->input->post('Name'));
$this->email->to($this->input->post('recipient'));        
$this->email->subject($this->input->post('Subject'));        
$this->email->message($this->input->post('message'));
            
if($this->email->send()){
       echo 'success.';
}else{
       show_error($this->email->print_debugger());
}
#2

[eluser]Johan André[/eluser]
It's because your server is not properly setup.
I had major trouble with this and I solved it (for now) by
using gmail smtp to send the mails...

/Johan
#3

[eluser]alrightythen[/eluser]
[quote author="Johan André" date="1263767072"]It's because your server is not properly setup.
I had major trouble with this and I solved it (for now) by
using gmail smtp to send the mails...

/Johan[/quote]


Do you know what exactly it is that was wrong with the server? I'm on a gridserver so I don't think I can change much but still. I would rather want a personal e-mail address to send the mails instead of a gmail one.
#4

[eluser]brianw1975[/eluser]
I had a lot of trouble with this a long time ago also.

For yahoo I needed to get DomainKeys installed and add the appropriate entry to the DNS for the domain.

for hotmail specifically look into SPF (Sender Policy Framework)
#5

[eluser]alrightythen[/eluser]
[quote author="brianw1975" date="1263772166"]I had a lot of trouble with this a long time ago also.

For yahoo I needed to get DomainKeys installed and add the appropriate entry to the DNS for the domain.

for hotmail specifically look into SPF (Sender Policy Framework)[/quote]

ugh what the hell I added a spf and used the regalur mail() function instead of the codeigniter e-mail class and it worked, but now a few hours later it stopped working!

I added a nlbr() function to give some white spacing in the input message. That mail went to junk so I removed the nlbr() and it's still in junk mail.

Please does someone have a solid solution for this?
#6

[eluser]brianw1975[/eluser]
Sorry, none of my users have made any complaints about not getting email in over 2 years, also i use phpmailer for all of my mail needs




Theme © iAndrew 2016 - Forum software by © MyBB