Template:IsIPAddress

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search
Template documentationview · edit · history · purge ]
This documentation is transcluded from Template:IsIPAddress/doc.

Returns 4 if the address is IPv4, 6 if IPv6, and a blank when not an IP address.

Usage

{{IsIPAddress |1= }}

Template parameters

ParameterDescriptionDefaultStatus
1Potential IP addressemptyrequired

Additional information

The template is intended to be used in the following namespaces: unknown

The template is intended to be used by the following user groups: all users

Relies on:
Module:IPAddress

Examples

{{IsIPAddress|127.0.0.1}}

renders as:

4


{{IsIPAddress|=00AB:0002:3008:8CFD:00AB:0002:3008:8CFD}}

renders as:

Localization

This template is not intended to be localized.