cliveportman/code

Redirect by IP address within ExpressionEngine template

This redirects visitors to the homepage if they aren't from the IP address, unless they're visiting the okay to show page:

{if segment_1 != "" && segment !="okay-to-show-page" && ip_address != "82.153.168.188"}{redirect=''}{/if}