Skip to content

Commit 28cf499

Browse files
committed
add 'all_headers' field
1 parent 211f8ad commit 28cf499

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

cleantalk.class.php

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ class CleantalkResponse {
4343
* @var int
4444
*/
4545
public $stop_words = null;
46-
46+
4747
/**
4848
* Cleantalk comment
4949
* @var string
@@ -185,6 +185,12 @@ function __construct($response = null, $obj = null) {
185185
*/
186186
class CleantalkRequest {
187187

188+
/**
189+
* All http request headers
190+
* @var string
191+
*/
192+
public $all_headers = null;
193+
188194
/**
189195
* User message
190196
* @var string
@@ -664,6 +670,7 @@ private function sendRequest($data = null, $url, $server_timeout = 3) {
664670
*/
665671
private function httpRequest($msg) {
666672
$result = false;
673+
$msg->all_headers=json_encode(apache_request_headers());
667674
if (((isset($this->work_url) && $this->work_url !== '') && ($this->server_changed + $this->server_ttl > time()))
668675
|| $this->stay_on_server == true) {
669676

0 commit comments

Comments
 (0)