From: Stefan Schantl Date: Mon, 24 Dec 2018 12:19:06 +0000 (+0100) Subject: ids.cgi: Hack to use the correct language string for red network zone. X-Git-Tag: v2.23-core131~117^2~118 X-Git-Url: http://git.ipfire.org/?p=ipfire-2.x.git;a=commitdiff_plain;h=53817b89c0eb5f03830777982c86c58e4c097fa6 ids.cgi: Hack to use the correct language string for red network zone. This hack is needed because "red" is used as "internet" in the language files and "red1" contains the correct "red" translations. Signed-off-by: Stefan Schantl --- diff --git a/html/cgi-bin/ids.cgi b/html/cgi-bin/ids.cgi index df8810a0bf..e3643f24cc 100644 --- a/html/cgi-bin/ids.cgi +++ b/html/cgi-bin/ids.cgi @@ -789,6 +789,14 @@ foreach my $zone (@network_zones) { # Convert current zone name to upper case. my $zone_upper = uc($zone); + # Set zone name. + my $zone_name = $zone; + + # Dirty hack to get the correct language string for the red zone. + if ($zone eq "red") { + $zone_name = "red1"; + } + # Grab checkbox status from settings hash. if ($idssettings{"ENABLE_IDS_$zone_upper"} eq "on") { $checked_input = "checked = 'checked'"; @@ -796,7 +804,7 @@ foreach my $zone (@network_zones) { print "\n"; print "\n"; - print " $Lang::tr{'enabled on'} $Lang::tr{$zone}\n"; + print " $Lang::tr{'enabled on'} $Lang::tr{$zone_name}\n"; print "\n"; }