Welcome Guest, Not a member yet? Register   Sign In
sending email hangs
#1

[eluser]pocketmax[/eluser]
every time I try to send an email using the email lib module, the page just hangs. Heres my code...

Code:
$this->load->library('email');
                $this->email->initialize(array(
                        'protocol'=>'smtp',
                        'smtp_port'=>25,
                        'smtp_host'=>'192.168.1.4',
                        'mailtype'=>'plain'
                ));
                $this->email->from('[email protected]');
                $this->email->reply_to('[email protected]');
                $this->email->to('[email protected]');
                $this->email->subject('my subject');
                $this->email->message('test body');
                $this->email->send();

I searched and there are about 3 or 4 previous posts about this issue but I'm totally convinced this is a bug and this is why...

1. I'm able to manually connect to port 25 on that ip using fsockopen in a separate script.
2. I telneted into port 25 on that server and did all the SMTP commands to make an email and send it to myself and it worked perfectly fine.

But when I load the email lib and do such a simple routine in ci, it just hangs. When I try a different ip address that I know doesn't have smtp turned on, it returns a connection timeout error. So that tells me that it does connect but something gets screwed up along the way.
#2

[eluser]pocketmax[/eluser]
bump
#3

[eluser]RiggsFolly[/eluser]
Very helpful.... bump.

I have a similiar problem, did you fix yours? If so could you post a solution?

Thanks
Hopeful.
#4

[eluser]pocketmax[/eluser]
Yeah, php mailer is rock solid. I would just use it as a lib and be done with it. Drop it into your library folder, load it as a library and go to town. It's one php file so you should be ok.




Theme © iAndrew 2016 - Forum software by © MyBB