Lines Matching refs:value

170                 $value = trim($h);
171 if ($value === '') {
175 $headers = [$value];
177 $headers[] = $value;
232 // [client][curl][body_as_string] request value is set.
296 foreach ($values as $value) {
297 $options[CURLOPT_HTTPHEADER][] = "$name: $value";
321 foreach ($config as $key => $value) {
323 $curlOptions[$key] = $value;
354 foreach ($request['client'] as $key => $value) {
359 if ($value === false) {
369 if (is_string($value)) {
370 $options[CURLOPT_CAINFO] = $value;
371 if (!file_exists($value)) {
373 "SSL CA bundle not found: $value"
381 if ($value === false) {
397 if (is_string($value)) {
398 if (!is_dir(dirname($value))) {
400 'Directory %s does not exist for save_to value of %s',
401 dirname($value),
402 $value
405 $value = new LazyOpenStream($value, 'w+');
408 if ($value instanceof StreamInterface) {
410 function ($ch, $write) use ($value) {
411 return $value->write($write);
413 } elseif (is_resource($value)) {
414 $options[CURLOPT_FILE] = $value;
424 $options[CURLOPT_TIMEOUT_MS] = $value * 1000;
426 $options[CURLOPT_TIMEOUT] = $value;
433 $options[CURLOPT_CONNECTTIMEOUT_MS] = $value * 1000;
435 $options[CURLOPT_CONNECTTIMEOUT] = $value;
441 if (!is_array($value)) {
442 $options[CURLOPT_PROXY] = $value;
445 if (isset($value[$scheme])) {
446 $options[CURLOPT_PROXY] = $value[$scheme];
453 if (is_array($value)) {
454 $options[CURLOPT_SSLCERTPASSWD] = $value[1];
455 $value = $value[0];
458 if (!file_exists($value)) {
460 "SSL certificate not found: {$value}"
464 $options[CURLOPT_SSLCERT] = $value;
469 if (is_array($value)) {
470 $options[CURLOPT_SSLKEYPASSWD] = $value[1];
471 $value = $value[0];
474 if (!file_exists($value)) {
476 "SSL private key not found: {$value}"
480 $options[CURLOPT_SSLKEY] = $value;
485 if (!is_callable($value)) {
493 function () use ($value) {
499 call_user_func_array($value, $args);
505 if ($value) {
506 $options[CURLOPT_STDERR] = Core::getDebugResource($value);