30)); if(!is_array($resp)){ gosmtp_notify(__('The response was malformed
'.var_export($resp, true)), 'error'); return; } $json = json_decode($resp['body'], true); if(empty($json['license'])){ gosmtp_notify(__('The license key is invalid'), 'error'); return; } $json['last_update'] = time(); update_option('gosmtp_license', $json); gosmtp_notify(__('Successfully updated the license key')); gosmtp_pro_load_license(); } function gosmtp_notify($message, $type = 'updated', $dismissible = true){ $is_dismissible = ''; if(!empty($dismissible)){ $is_dismissible = 'is-dismissible'; } if(!empty($message)){ echo '

'.$message.'

'; } } if(isset($_REQUEST['save_gosmtp_license'])){ gosmtp_license(); } ?>

license['license']) ? 'Unlicensed    ' : '')?>  
license['license'])){ $expires = $gosmtp->license['expires']; $expires = substr($expires, 0, 4).'/'.substr($expires, 4, 2).'/'.substr($expires, 6); echo '
License Status : '.(empty($gosmtp->license['status_txt']) ? 'N.A.' : wp_kses_post($gosmtp->license['status_txt'])).'       License Expires : '.($gosmtp->license['expires'] <= date('Ymd') ? ''.esc_attr($expires).'' : esc_attr($expires)).'
'; }?>
URL
Path
.htaccess Yes' : 'No');?>