File tree Expand file tree Collapse file tree 3 files changed +28
-0
lines changed Expand file tree Collapse file tree 3 files changed +28
-0
lines changed Original file line number Diff line number Diff line change @@ -211,6 +211,7 @@ Curl::getCookie($key)
211
211
Curl::getInfo($opt = null)
212
212
Curl::getOpt($option)
213
213
Curl::getResponseCookie($key)
214
+ Curl::getResponseCookies()
214
215
Curl::head($url, $data = array())
215
216
Curl::options($url, $data = array())
216
217
Curl::patch($url, $data = array())
Original file line number Diff line number Diff line change
1
+ <?php
2
+ require __DIR__ . '/../vendor/autoload.php ' ;
3
+
4
+ use \Curl \Curl ;
5
+
6
+ $ curl = new Curl ();
7
+ $ curl ->get ('https://secure.php.net/ ' );
8
+
9
+ if ($ curl ->error ) {
10
+ echo 'Error: ' . $ curl ->errorCode . ': ' . $ curl ->errorMessage . "\n" ;
11
+ } else {
12
+ echo 'Response cookies: ' . "\n" ;
13
+ var_dump ($ curl ->responseCookies );
14
+ var_dump ($ curl ->getResponseCookies ());
15
+ }
Original file line number Diff line number Diff line change @@ -745,6 +745,18 @@ public function getResponseCookie($key)
745
745
return isset ($ this ->responseCookies [$ key ]) ? $ this ->responseCookies [$ key ] : null ;
746
746
}
747
747
748
+ /**
749
+ * Get Response Cookies
750
+ *
751
+ * @access public
752
+ *
753
+ * @return array
754
+ */
755
+ public function getResponseCookies ()
756
+ {
757
+ return $ this ->responseCookies ;
758
+ }
759
+
748
760
/**
749
761
* Set Max Filesize
750
762
*
You can’t perform that action at this time.
0 commit comments