From 436bd155bf5e662165de16763929339a226f6286 Mon Sep 17 00:00:00 2001 From: Max Base Date: Sat, 17 Aug 2019 20:30:19 +0430 Subject: [PATCH 1/6] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 4101970..9738f9d 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,3 @@ -# NetPHP +# Net PHP Useful functions for connecting to the network in the PHP based applications. From 39dd517cba3b98afe7f8b22752b709c9ffe8ddec Mon Sep 17 00:00:00 2001 From: Max Base Date: Sat, 17 Aug 2019 20:31:22 +0430 Subject: [PATCH 2/6] Update README.md --- README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/README.md b/README.md index 9738f9d..3add691 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,13 @@ # Net PHP Useful functions for connecting to the network in the PHP based applications. + +## Features + +- Send GET Requests +- Send POST Requests +- Support Cookie Manager +- Ability to send headers to requests +- Ability to set the referrer URL header. +- Parse Response Headers +- Detect 404 pages and return a False value(bool)... [[v1.1]](https://github.com/BaseMax/NetPHP/releases/tag/1.1) From 9bd36a6caab28cf3eabce2408f56a249fca13217 Mon Sep 17 00:00:00 2001 From: Max Base Date: Sat, 17 Aug 2019 20:31:36 +0430 Subject: [PATCH 3/6] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 3add691..b376c89 100644 --- a/README.md +++ b/README.md @@ -10,4 +10,4 @@ Useful functions for connecting to the network in the PHP based applications. - Ability to send headers to requests - Ability to set the referrer URL header. - Parse Response Headers -- Detect 404 pages and return a False value(bool)... [[v1.1]](https://github.com/BaseMax/NetPHP/releases/tag/1.1) +- Detect 404 pages and return a `False` value(bool)... [[v1.1]](https://github.com/BaseMax/NetPHP/releases/tag/1.1) From 37ab54706a52a56b18e3b9e92a5543c1e1111737 Mon Sep 17 00:00:00 2001 From: Max Base Date: Sat, 17 Aug 2019 20:35:14 +0430 Subject: [PATCH 4/6] Solve curl_getinfo() error... `curl_getinfo(): supplied resource is not a valid cURL handle resource` --- NetPHP.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/NetPHP.php b/NetPHP.php index ee59fe0..8343840 100644 --- a/NetPHP.php +++ b/NetPHP.php @@ -73,6 +73,7 @@ function post($url,$values,$headers=[],$reffer="",$auto_redirect=true) { $header_size = curl_getinfo($curl,CURLINFO_HEADER_SIZE); $header = substr($response,0,$header_size); $body = substr($response,$header_size); + $httpCode = curl_getinfo($curl,CURLINFO_HTTP_CODE); curl_close($curl); if($debug && $debug_details) { print "----------@Response Headers\n"; @@ -81,7 +82,6 @@ function post($url,$values,$headers=[],$reffer="",$auto_redirect=true) { print_r($body); print "\n"; } - $httpCode = curl_getinfo($curl,CURLINFO_HTTP_CODE); if($httpCode == 404) { return false; } @@ -124,6 +124,7 @@ function get($url,$headers=[],$reffer="",$auto_redirect=true) $header_size = curl_getinfo($curl,CURLINFO_HEADER_SIZE); $header = substr($response,0,$header_size); $body = substr($response,$header_size); + $httpCode = curl_getinfo($curl,CURLINFO_HTTP_CODE); curl_close($curl); if($debug && $debug_details) { print "----------@Response Headers\n"; @@ -132,7 +133,6 @@ function get($url,$headers=[],$reffer="",$auto_redirect=true) print_r($body); print "\n"; } - $httpCode = curl_getinfo($curl,CURLINFO_HTTP_CODE); if($httpCode == 404) { return false; } From 8d6b3a68885d3d57ac4881d99eb3ea8dd05a4e57 Mon Sep 17 00:00:00 2001 From: Max Base Date: Tue, 19 May 2020 19:31:21 +0430 Subject: [PATCH 5/6] Update NetPHP.php --- NetPHP.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NetPHP.php b/NetPHP.php index 8343840..5fe5fed 100644 --- a/NetPHP.php +++ b/NetPHP.php @@ -32,7 +32,7 @@ function get_headers_from_curl_response($headerContent) { } return $headers; } -function post($url,$values,$headers=[],$reffer="",$auto_redirect=true) { +function post($url,$values=[],$headers=[],$reffer="",$auto_redirect=true) { global $debug,$debug_details; if($debug) { print "@Request[POST]----------------------------------------------\n"; From 06038abd3cd9009f5c01130ece1ab9f80901787c Mon Sep 17 00:00:00 2001 From: Max Base Date: Wed, 27 May 2020 03:11:57 +0430 Subject: [PATCH 6/6] Update README.md --- README.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/README.md b/README.md index b376c89..d2e5790 100644 --- a/README.md +++ b/README.md @@ -11,3 +11,15 @@ Useful functions for connecting to the network in the PHP based applications. - Ability to set the referrer URL header. - Parse Response Headers - Detect 404 pages and return a `False` value(bool)... [[v1.1]](https://github.com/BaseMax/NetPHP/releases/tag/1.1) + +--------- + +# Max Base + +My nickname is Max, Programming language developer, Full-stack programmer. I love computer scientists, researchers, and compilers. ([Max Base](https://maxbase.org/)) + +## Asrez Team + +A team includes some programmer, developer, designer, researcher(s) especially Max Base. + +[Asrez Team](https://www.asrez.com/)