function getHeaders()
Array
(
[Host] => fuhrer.web.id
[User-Agent] => Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
[Accept] => */*
[Accept-Encoding] => gzip, br
[Cdn-Loop] => cloudflare; loops=1
[Cf-Ipcountry] => US
[Cf-Ray] => 99ff722c89e8aadc-YYZ
[Cf-Visitor] => {"scheme":"https"}
[Cf-Warp-Tag-Id] => 6c974b78-a302-47db-92de-a0bddbbf165b
[Connection] => keep-alive
[X-Forwarded-For] => 216.73.216.43
[X-Forwarded-Proto] => https
)
Example #1 getallheaders() example
Host: fuhrer.web.id
User-Agent: Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
Accept: */*
Accept-Encoding: gzip, br
Cdn-Loop: cloudflare; loops=1
Cf-Ipcountry: US
Cf-Ray: 99ff722c89e8aadc-YYZ
Cf-Visitor: {"scheme":"https"}
Cf-Warp-Tag-Id: 6c974b78-a302-47db-92de-a0bddbbf165b
Connection: keep-alive
X-Forwarded-For: 216.73.216.43
X-Forwarded-Proto: https
Example #3 Example using headers_list()
Array
(
[0] => X-Powered-By: PHP/8.3.27
[1] => Content-type: text/html; charset=UTF-8
)
It will list everything within the array
Array
(
[HTTP_HOST] => fuhrer.web.id
[HTTP_USER_AGENT] => Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
[HTTP_ACCEPT] => */*
[HTTP_ACCEPT_ENCODING] => gzip, br
[HTTP_CDN_LOOP] => cloudflare; loops=1
[HTTP_CF_IPCOUNTRY] => US
[HTTP_CF_RAY] => 99ff722c89e8aadc-YYZ
[HTTP_CF_VISITOR] => {"scheme":"https"}
[HTTP_CF_WARP_TAG_ID] => 6c974b78-a302-47db-92de-a0bddbbf165b
[HTTP_CONNECTION] => keep-alive
[HTTP_X_FORWARDED_FOR] => 216.73.216.43
[HTTP_X_FORWARDED_PROTO] => https
[PATH] => /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/snap/bin
[SERVER_SIGNATURE] =>
[SERVER_SOFTWARE] => Apache/2.4.58 (Ubuntu)
[SERVER_NAME] => fuhrer.web.id
[SERVER_ADDR] => 192.168.1.219
[SERVER_PORT] => 80
[REMOTE_ADDR] => 216.73.216.43
[DOCUMENT_ROOT] => /data/html/vhost/fuhrer.web.id/public_html
[REQUEST_SCHEME] => http
[CONTEXT_PREFIX] =>
[CONTEXT_DOCUMENT_ROOT] => /data/html/vhost/fuhrer.web.id/public_html
[SERVER_ADMIN] => webmaster@localhost
[SCRIPT_FILENAME] => /data/html/vhost/fuhrer.web.id/public_html/azenv.php
[REMOTE_PORT] => 33856
[GATEWAY_INTERFACE] => CGI/1.1
[SERVER_PROTOCOL] => HTTP/1.1
[REQUEST_METHOD] => GET
[QUERY_STRING] =>
[REQUEST_URI] => /azenv.php
[SCRIPT_NAME] => /azenv.php
[PHP_SELF] => /azenv.php
[REQUEST_TIME_FLOAT] => 1763384793.8301
[REQUEST_TIME] => 1763384793
[argv] => Array
(
)
[argc] => 0
)
AZ Environment variables 1.04
HTTP_HOST = fuhrer.web.id
HTTP_USER_AGENT = Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
HTTP_ACCEPT = */*
HTTP_ACCEPT_ENCODING = gzip, br
HTTP_CDN_LOOP = cloudflare; loops=1
HTTP_CF_IPCOUNTRY = US
HTTP_CF_RAY = 99ff722c89e8aadc-YYZ
HTTP_CF_VISITOR = {"scheme":"https"}
HTTP_CF_WARP_TAG_ID = 6c974b78-a302-47db-92de-a0bddbbf165b
HTTP_CONNECTION = keep-alive
HTTP_X_FORWARDED_FOR = 216.73.216.43
HTTP_X_FORWARDED_PROTO = https
REMOTE_ADDR = 216.73.216.43
REQUEST_SCHEME = http
REMOTE_PORT = 33856
REQUEST_METHOD = GET
REQUEST_URI = /azenv.php
REQUEST_TIME_FLOAT = 1763384793.8301
REQUEST_TIME = 1763384793