rah_ip_range

Published under current TXP projects

Block or allow visitors based on their IP. You can define a IP range, and what to do those whose IP is within the range; either allow, or opposite, deny them and allow others outside that range to see the page.

Download rah_ip_range v0.1

Image: rah_ip_range

Image: rah_ip_range

List of features

Attributes

The tag is <txp:rah_ip_range /> attributes for it follow. Use the tag on places (pages/forms/sections) which you want to restrict from visitors.

message
Error message shown to blocked visitors. Message can be shown with the <txp:error_message /> tag.
Default: message="Access denied" Example: "KO"

status
HTTP error status code returned to blocked visitors.
Default: status="503" Example: "200"

fromip
IP-range’s starting IP (or partial IP). Default unset.
Default: fromip="" Example: "127.0.0.1"

toip
IP-range’s ending IP (or partial IP). Default unset.
Default: toip="" Example: "127.0.0.100"

method
What to do to the visitor when IP is within the range; either deny or allow. Value deny means that all visitors within the range are blocked, and others (outside) are allowed to see the page. Value allow is opposite to deny.
Default: method="allow" Example: "deny"

Example

<txp:rah_ip_range fromip="127.0.0.1" toip="127.0.0.100" method="deny" />

Changelog

Version 0.1