Project

General

Profile

$iptype » History » Version 1

Per Amundsen, 08/12/2015 12:53 PM

1 1 Per Amundsen
_Added in 1.9.3_
2
3
*$iptype(text)*
4
5
Returns "ipv4" or "ipv6" if text is is a valid IP address format.
6
7
*Parameters*
8
9
text - The text to validate.
10
11
*Properties*
12
13
-expand - Expand an ipv6 address.
14
.compress - Compress an ipv6 address.
15
16
*Example*
17
18
<pre>
19
; Check a IPv4 address.
20
//echo -ag 8.8.8.8 is $iptype(8.8.8.8)
21
22
; Check a IPv6 address.
23
//echo -ag FE80:0000:0000:0000:0202:B3FF:FE1E:8329 is $iptype(FE80:0000:0000:0000:0202:B3FF:FE1E:8329)
24
</pre>