mirror of
https://github.com/tuxis-ie/nsedit.git
synced 2025-04-19 20:09:14 +03:00
Merge pull request #60 from bfbones/master
add VERFIYPEER option to main api-request
This commit is contained in:
commit
d23296e742
1 changed files with 3 additions and 0 deletions
|
@ -41,6 +41,9 @@ function api_request($path, $opts = null, $type = null) {
|
|||
} else {
|
||||
curl_setopt($ch, CURLOPT_USERPWD, "$apiuser:$apipass");
|
||||
}
|
||||
if ( strcasecmp( $apiproto, 'https' ) == 0 ) {
|
||||
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, $apisslverify);
|
||||
}
|
||||
curl_setopt($ch, CURLOPT_URL, $url);
|
||||
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
|
||||
if ($opts) {
|
||||
|
|
Loading…
Add table
Reference in a new issue