Note that there are some explanatory texts on larger screens.

plurals
  1. POgmail smtp not working in my hosting using codeigniter framework
    text
    copied!<p>i wish to use gmail smtp to send user information to the registered email. </p> <p>The code that i am using is working fine in my localhost, but when i changed into shared hosting it come out with the below error.</p> <pre><code>A PHP Error was encountered Severity: Warning Message: fsockopen() [function.fsockopen]: unable to connect to ssl://smtp.googlemail.com:465 (Connection timed out) Filename: libraries/Email.php Line Number: 1652 A PHP Error was encountered Severity: Warning Message: fwrite(): supplied argument is not a valid stream resource Filename: libraries/Email.php Line Number: 1795 .... (more error msg here) An Error Was Encountered The following SMTP error was encountered: 110 Connection timed out Unable to send data: AUTH LOGIN Failed to send AUTH LOGIN command. Error: Unable to send data: MAIL FROM: from: The following SMTP error was encountered: Unable to send data: RCPT TO: to: The following SMTP error was encountered: Unable to send data: DATA .... (more error msg here) </code></pre> <p>Here's my email config </p> <blockquote> <pre><code>$pass = $this-&gt;generatePassword('6'); $config = Array( 'protocol' =&gt; 'smtp', 'smtp_host' =&gt; 'ssl://smtp.googlemail.com', 'smtp_port' =&gt; 465, 'smtp_timeout'=&gt;'30', 'smtp_user' =&gt; 'username@gmail.com', 'smtp_pass' =&gt; 'mypassword', 'mailtype' =&gt; 'html', 'charset' =&gt; 'iso-8859-1' ); $this-&gt;load-&gt;library('email', $config); $this-&gt;email-&gt;set_newline("\r\n"); $this-&gt;email-&gt;from('admin@lalala.com','Title'); $this-&gt;email-&gt;to($this-&gt;input-&gt;post('email')); $this-&gt;email-&gt;subject('Subject here'); $this-&gt;email-&gt;message('Your login username is '.$this-&gt;input-&gt;post('username').'&lt;br/&gt;'.'Password is '.$pass); if (!$this-&gt;email-&gt;send()){ show_error($this-&gt;email-&gt;print_debugger()); }else{ echo 'YEAH!!!';} </code></pre> </blockquote> <p>i try to check my share hosting openssl whether is enabled or not. and i found this</p> <p>openssl OpenSSL support enabled<br> OpenSSL Version OpenSSL 0.9.8e-fips-rhel5 01 Jul 2008 </p> <p>If openssl is enabled. still what will be the mistake in my code? </p> <p>I start to be frustrated to use my localhost to develop and when its uploaded to share hosting, it came out wit lots of error. </p> <p>Any help would be appreciate!! thx in advanced</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload