Help for this page

Select Code to Download


  1. or download this
    m/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}\$/;
    
  2. or download this
    use strict;
    my @nums;
    ...
    
    # test each for <= 255 here.
    # also make sure its not 0.0.0.0
    
  3. or download this
    m/^([01]?\d\d?|2[0-4]\d|25[0-5])\.([01]?\d\d?|2[0-4]\d|25[0-5])\.
       ([01]?\d\d?|2[0-4]\d|25[0-5])\.([01]?\d\d?|2[0-4]\d|25[0-5])$/;