Welcome Guest, Not a member yet? Register   Sign In
Email class using smtp protocol. pls help
#1

[eluser]eironotics[/eluser]
scenario
i am developing an intranet application that can generate email alert to any recipient.
Our mail server is located in a different machine call it 192.168.20.15 and I am using a Exchange Mail Server.

Problem:
I recieve this kind of an error:
Fatal error: Maximum execution time of 60 seconds exceeded in F:\xampp\htdocs\CodeIgniter\system\libraries\Email.php on line 1704

whats this suppose to mean?
any ideas? please help..


heres my code at controller


Code:
$this->load->library('email');
        $this->load->helper('email');
    
        $config['protocol'] = "smtp";
        $config['smtp_host'] = "192.168.20.15";
        $config['smtp_user'] = "[email protected]";
        $config['smtp_pass'] = "password";
        $config['smtp_port'] = "25";
        $config['charset'] = "iso-8859-1";
        $config['wordwrap'] = TRUE;
        
        $this->email->initialize($config);
        $this->email->to('[email protected]');
        
        $this->email->subject('Email Test');
        $this->email->message('Testing the email class.');
        $this->email->send();
#2

[eluser]JGarrido[/eluser]
I've actually been having the same issue with the native emailing mechanism, but have had success with the SwiftMailer library. I'm now trying to use Redux Auth, which uses the native email library, so now I'm up against the same wall again. Developing locally, and deploying remotely (remotely, there's no problem, except that Yahoo doesn't seem to want to render the actual email body, but that's probably a different issue...).
#3

[eluser]JGarrido[/eluser]
I've been trying to do some dirty debugging just inserting echo statements, and so far I have the problem narrowed down to the _send_command > _send_data('EHLO '... call (the difference is my timeout occurs after 30 seconds, instead of your 60 seconds - not sure where that setting is).

Comcast actually blocked my port 25 the other day while attempting to work on this problem, I'm just hoping they don't do it again as I troubleshoot this...
#4

[eluser]eironotics[/eluser]
ive been searching on the bug tracker but my problem is not a bug of CI.
maybe it is how I configure my smtp?
watcha think guys? Please review my configuration? is it correct in config array?
#5

[eluser]JGarrido[/eluser]
Please let me know if you're able to solve this one; I wound up just configuring Redux Auth to use SwiftMailer - bypassing the native mailing function - and this should be fine for now, but I'd really like to know what causes this issue.
#6

[eluser]eironotics[/eluser]
yah.. i have not found the solution on the CI class. I end up configuring the php mailer using smtp and it works just fine...
#7

[eluser]JGarrido[/eluser]
Based on some search results on the forum, this seems to be a fairly common issue; and it seems that using a Windows OS is a common thread, I'm thinking they're all related. It'd be good to be able to submit these kinds of issues for investigation. It should probably be submitted as a bug.
#8

[eluser]Joseph1982[/eluser]
[quote author="eironotics" date="1219255403"]
[b]Fatal error: Maximum execution time of 60 seconds exceeded in F:\xampp\htdocs\CodeIgniter\system\libraries\Email.php on line 1704[/quote]


How can I change the Maximum Execution time in CodeIgniter? Where can I add the function call set_time_limit(0) to set the execution time as unlimited?

Regards,
Joseph.
#9

[eluser]soar[/eluser]
I have the same error in CI 1.7.0 - I think this is CI bug.

It looks like error in getting answers from server: script not send request, after first 220-message. I tried to emulate protocol handshaking:

Code:
220 example.com ESMTP CommuniGate Pro 5.1c.4 is glad to see you! // Nothing here
220 example.com ESMTP CommuniGate Pro 5.1c.4 is glad to see you! // And only after 2 request we have:
AUTH LOGIN

Script wait for second SMTP-server answer, SMTP-server waiting for request. Maybe problem in various line-breaks symbols ? Tested with SMTP-server on Linux and CI on Win32 web-server.

PS: sorry for my bad english
#10

[eluser]soar[/eluser]
Confirmed: same script working on Linux and DOn't working on Windows - tested with *nix SMTP-server.




Theme © iAndrew 2016 - Forum software by © MyBB