class PantheonCurl in Search API Pantheon 8
Hierarchy
- class \Drupal\search_api_pantheon\Solarium\PantheonCurl extends \Solarium\Core\Client\Adapter\Curl
Expanded class hierarchy of PantheonCurl
File
- src/
Solarium/ PantheonCurl.php, line 11 - Override Solarium so that more options can be set before executing curl.
Namespace
Drupal\search_api_pantheon\SolariumView source
class PantheonCurl extends Curl {
/**
* {@inheritdoc}
*/
public function createHandle($request, $endpoint) {
$handler = parent::createHandle($request, $endpoint);
if (defined('PANTHEON_ENVIRONMENT')) {
curl_setopt($handler, CURLOPT_SSL_VERIFYPEER, FALSE);
$client_cert = $_SERVER['HOME'] . '/certs/binding.pem';
curl_setopt($handler, CURLOPT_SSLCERT, $client_cert);
}
return $handler;
}
}
Members
Name![]() |
Modifiers | Type | Description | Overrides |
---|---|---|---|---|
PantheonCurl:: |
public | function |