Welcome Guest, Not a member yet? Register   Sign In
fsockopen error with php 7.0
#5

I have updated my servers that have PHP 5.x to 5.6 and 7, then i got same error like above.

Try this:

Disable this code:
Code:
//PHP 5.3 Only
        /*
        $this->_smtp_connect = fsockopen($ssl.$this->smtp_host,
                            $this->smtp_port,
                            $errno,
                            $errstr,
                            $this->smtp_timeout);
        */

Add this lines below disabled codes:

Code:
//PHP 5.6 & 7.0 Only Configuration
$context = stream_context_create(['ssl' => [
  //'ciphers' => 'RC4-MD5',
  'verify_host' => FALSE,
  'verify_peer_name' => FALSE,
  'verify_peer' => FALSE
]]);

$this->_smtp_connect = stream_socket_client($ssl.$this->smtp_host.':'.$this->smtp_port, $errno, $errstr, 30, STREAM_CLIENT_CONNECT, $context);
//END OF PHP 5.6 & 7.0 Only Configuration

Hope this solves that problem. Thank you.
Reply


Messages In This Thread
fsockopen error with php 7.0 - by alfred.laggner - 02-21-2016, 05:02 PM
RE: fsockopen error with php 7.0 - by freddy - 02-21-2016, 07:20 PM
RE: fsockopen error with php 7.0 - by novianbiz - 12-29-2016, 09:15 PM
RE: fsockopen error with php 7.0 - by InsiteFX - 12-30-2016, 05:22 AM



Theme © iAndrew 2016 - Forum software by © MyBB