1
0
mirror of synced 2025-02-11 17:59:26 +03:00

Merge pull request #1 from dmamontov/master

Replaced CURLOPT_HTTPHEADER on CURLOPT_USERPWD
This commit is contained in:
Dmitry Mamontov 2015-01-26 13:10:42 +03:00
commit ff8790d3e2

View File

@ -401,15 +401,8 @@ class MoySkladICMLParser
$ch = curl_init();
$securityStr = base64_encode($this->login.':'.$this->pass);
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt(
$ch,
CURLOPT_HTTPHEADER,
array(
"Authorization: Basic ".$securityStr."\r\n", // авторизация
)
);
curl_setopt($ch, CURLOPT_USERPWD, $this->login . ':' . $this->pass);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); // возвращаем результат
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, self::TIMEOUT);