}
/**
- * @param null $connectionTimeout
+ * @param int|null $connectionTimeout
+ * seconds; or NULL to use system default
*/
public function __construct($connectionTimeout = NULL) {
$this->connectionTimeout = $connectionTimeout;
list($ch, $caConfig) = $this->createCurl($remoteFile);
if (preg_match('/^https:/', $remoteFile) && !$caConfig->isEnableSSL()) {
- // CRM_Core_Error::fatal('Cannot install this extension - does not support SSL');
return [self::STATUS_DL_ERROR, NULL];
}
public function post($remoteFile, $params) {
// Download extension zip file ...
if (!function_exists('curl_init')) {
- //CRM_Core_Error::fatal('Cannot install this extension - curl is not installed!');
return [self::STATUS_DL_ERROR, NULL];
}
list($ch, $caConfig) = $this->createCurl($remoteFile);
if (preg_match('/^https:/', $remoteFile) && !$caConfig->isEnableSSL()) {
- // CRM_Core_Error::fatal('Cannot install this extension - does not support SSL');
return [self::STATUS_DL_ERROR, NULL];
}
* @return bool
*/
public function isRedirectSupported() {
- return (ini_get('open_basedir') == '') && (ini_get('safe_mode') == 'Off' || ini_get('safe_mode') == '' || ini_get('safe_mode') === FALSE);
+ return (ini_get('open_basedir') == '');
}
}