in reply to Save Split to Array
Here is sample validation code for vlan name:
Similarly, the vlan number numeric check should be:if ( $vlan_name =~ m|^\w[\w-]*$| ){ # Name complies with : # * At least one char # * Starts with a letter, number or underscore # * Contains only alpha, num, underscore, hyphem }else{ # Complain about non-compliant name }
if ($vlan_number =~ m|^\d+$|) { # Compliant - numeric only }else{ # Something Not completely numeric - display error. }
Potentia vobiscum ! (Si hoc legere scis nimium eruditionis habes)
|
|---|