Call a function/run code on every page that is visited

I will start using Cloudflare soon and because all IPs are the same for every visitor i need to rewrite these to the real ones given in a special HTTP header by cloudflare. To make the IPs visible to dolphin system wide i need to run this code on every page that is called

if ($_SERVER["HTTP_CF_CONNECTING_IP"]) {
       $_SERVER["REMOTE_ADDR"] = $_SERVER["HTTP_CF_CONNECTING_IP"];
}


Where is the correct place to put such a code? Anybody knows?

Check my GeoDistance, Watermark, TorBlock and Android Push Notifications mods | http://goo.gl/H3Vp81
Quote · 23 Aug 2012

Not entirely certain on this one, but I'd start with the _header.html file from within your current template directory. 

 

This will present the code on every page of your Dolphin site.

Skype: shawn.nelson
Quote · 23 Aug 2012

well...   you cant run php inside an html file...   so maybe  /inc/header.inc.php would be a better place to start.

https://dolphin-techs.com - Skype: Dolphin Techs
Quote · 23 Aug 2012

in design.inc.php line 124

PageCode function.

Good luck

so much to do....
Quote · 24 Aug 2012

PageCode() -> Perfect, this is what i was looking for :)

Thanks

Check my GeoDistance, Watermark, TorBlock and Android Push Notifications mods | http://goo.gl/H3Vp81
Quote · 24 Aug 2012

 

PageCode() -> Perfect, this is what i was looking for :)

Thanks

 you're welcome :)

so much to do....
Quote · 24 Aug 2012
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.