Cloudflare...

Artixius

Member
Nov 16, 2011
53
9
How can I configure the api so when I use cloudflare it will go directly to the client? When I do not use cloudflare it does, when I use cloudflare it doesn't work and just stays at the api when you press the vote button.
 

JoshuaLuke

Posting Freak
Jan 29, 2012
529
51
Put this on the top of your API config file:

Code:
if (isset($_SERVER['HTTP_CF_CONNECTING_IP'])) { $_SERVER['REMOTE_ADDR'] = $_SERVER['HTTP_CF_CONNECTING_IP']; }
 

Users who are viewing this thread

Top