How do I restore original visitor IP for XenForo on Cloudflare
|option 1:
Login to your Xenforo Root folder
- open library/config.php
- At the end, add:
if (isset($_SERVER[‘HTTP_CF_CONNECTING_IP’])) { $_SERVER[‘REMOTE_ADDR’] = $_SERVER[‘HTTP_CF_CONNECTING_IP’]; } - upload and overwrite
Another option 2:
A Xenforo user has created a plugin that is available here. Download and upload plugin enable it.