Fixes capitilization of header
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
<?php
|
||||
// Will check if this is requested through cloudflare
|
||||
if (array_key_exists("cf-connecting-ip", apache_request_headers())) {
|
||||
$address = sanitize(apache_request_headers()["cf-connecting-ip"]);
|
||||
if (! $address) {
|
||||
if (array_key_exists("Cf-Connecting-Ip", apache_request_headers())) {
|
||||
$address = sanitize(apache_request_headers()["Cf-Connecting-Ip"]);
|
||||
if (!$address) {
|
||||
$address = $_SERVER["REMOTE_ADDR"]; // Variable that stores the IP address of user accessing the website
|
||||
}
|
||||
} else {
|
||||
$address = $_SERVER["REMOTE_ADDR"];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user