You are here

function smtp_update_7104 in SMTP Authentication Support 7

Same name and namespace in other branches
  1. 7.2 smtp.install \smtp_update_7104()

Add "smtp_verify_peer", "smtp_verify_peer_name", "smtp_allow_self_signed" variables based on current running PHP version for most compatibility.

File

./smtp.install, line 141
The installation instructions for the SMTP Authentication Support.

Code

function smtp_update_7104() {
  if (version_compare(phpversion(), '5.6.0', '>=')) {
    variable_set('smtp_verify_peer', TRUE);
    variable_set('smtp_verify_peer_name', TRUE);
  }
  else {
    variable_set('smtp_verify_peer', FALSE);
  }
  variable_set('smtp_allow_self_signed', FALSE);
}