mirror of
https://github.com/webmin/webmin.git
synced 2025-07-21 23:40:34 +00:00
Allow hostnames to be entered as well as IPs
This commit is contained in:
@ -18,7 +18,7 @@ print &ui_hidden("new", $in{'new'}),"\n";
|
||||
print &ui_hidden("idx", $in{'idx'}),"\n";
|
||||
print &ui_table_start($text{'ipkey_header'}, undef, 2);
|
||||
|
||||
print &ui_table_row($text{'ipkey_ips'},
|
||||
print &ui_table_row($text{'ipkey_ips2'},
|
||||
&ui_textarea("ips", join("\n", @{$ipkey->{'ips'}}),
|
||||
3, 20));
|
||||
|
||||
|
@ -22,7 +22,7 @@ else {
|
||||
@ips = split(/\s+/, $in{'ips'});
|
||||
foreach $i (@ips) {
|
||||
&check_ipaddress($i) || &check_ip6address($i) ||
|
||||
&error(&text('ipkey_eip', $i));
|
||||
&to_ipaddress($i) || &error(&text('ipkey_eip2', $i));
|
||||
}
|
||||
@ips || &error(&text('ipkey_eips'));
|
||||
$ipkey->{'ips'} = \@ips;
|
||||
|
Reference in New Issue
Block a user