aboutsummaryrefslogtreecommitdiffstats
path: root/include/network.php
diff options
context:
space:
mode:
authorredmatrix <git@macgirvin.com>2016-06-27 22:25:37 -0700
committerredmatrix <git@macgirvin.com>2016-06-27 22:25:37 -0700
commit7d7f43c2056fd50ff26aed5df553bf4936ead196 (patch)
tree8aa181cc6c1c60a803178976be03ddfa1981b7d1 /include/network.php
parent30a5fe30617ef19d7cb896783442d43277ce5a8e (diff)
downloadvolse-hubzilla-7d7f43c2056fd50ff26aed5df553bf4936ead196.tar.gz
volse-hubzilla-7d7f43c2056fd50ff26aed5df553bf4936ead196.tar.bz2
volse-hubzilla-7d7f43c2056fd50ff26aed5df553bf4936ead196.zip
still working through some issues with curl magic-auth
fixed profile photo upload
Diffstat (limited to 'include/network.php')
-rw-r--r--include/network.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/network.php b/include/network.php
index 96bf714f6..47863b680 100644
--- a/include/network.php
+++ b/include/network.php
@@ -101,6 +101,9 @@ function z_fetch_url($url, $binary = false, $redirects = 0, $opts = array()) {
if(x($opts,'cookiefile'))
@curl_setopt($ch, CURLOPT_COOKIEFILE, $opts['cookiefile']);
+ if(x($opts,'cookie'))
+ @curl_setopt($ch, CURLOPT_COOKIE, $opts['cookie']);
+
@curl_setopt($ch, CURLOPT_SSL_VERIFYPEER,
((x($opts,'novalidate') && intval($opts['novalidate'])) ? false : true));
@@ -258,6 +261,10 @@ function z_post_url($url,$params, $redirects = 0, $opts = array()) {
if(x($opts,'cookiefile'))
@curl_setopt($ch, CURLOPT_COOKIEFILE, $opts['cookiefile']);
+
+ if(x($opts,'cookie'))
+ @curl_setopt($ch, CURLOPT_COOKIE, $opts['cookie']);
+
@curl_setopt($ch, CURLOPT_SSL_VERIFYPEER,
((x($opts,'novalidate') && intval($opts['novalidate'])) ? false : true));