From 20730a6feee96496d4933fc2cba54e0c87b7ef84 Mon Sep 17 00:00:00 2001 From: Jan Paul Tuecking Date: Fri, 27 May 2011 14:00:57 +0200 Subject: [PATCH 1/4] extrahd.cgi: removed controller names from list, corrected translation. --- html/cgi-bin/extrahd.cgi | 56 +++++++++++++++++++++++----------------- 1 file changed, 33 insertions(+), 23 deletions(-) diff --git a/html/cgi-bin/extrahd.cgi b/html/cgi-bin/extrahd.cgi index 3bb6afd8d..7cdad0161 100644 --- a/html/cgi-bin/extrahd.cgi +++ b/html/cgi-bin/extrahd.cgi @@ -2,7 +2,7 @@ ############################################################################### # # # IPFire.org - A linux based firewall # -# Copyright (C) 2010 IPFire Team # +# Copyright (C) 2011 IPFire Team # # # # This program is free software: you can redistribute it and/or modify # # it under the terms of the GNU General Public License as published by # @@ -79,11 +79,11 @@ if ($extrahdsettings{'ACTION'} eq $Lang::tr{'add'}) @deviceline = split( /\;/, $deviceentry ); if ( "$extrahdsettings{'PATH'}" eq "$deviceline[2]" ) { $ok = "false"; - $errormessage = "You can't mount $extrahdsettings{'DEVICE'} to $extrahdsettings{'PATH'}, because there is already a device mounted."; + $errormessage = "$Lang::tr{'extrahd you cant mount'} $extrahdsettings{'DEVICE'} $Lang::tr{'extrahd to'} $extrahdsettings{'PATH'}$Lang::tr{'extrahd because there is already a device mounted'}."; } if ( "$extrahdsettings{'PATH'}" eq "/" ) { $ok = "false"; - $errormessage = "You can't mount $extrahdsettings{'DEVICE'} to root /."; + $errormessage = "$Lang::tr{'extrahd you cant mount'} $extrahdsettings{'DEVICE'} $Lang::tr{'extrahd to root'}."; } } @@ -113,7 +113,7 @@ elsif ($extrahdsettings{'ACTION'} eq $Lang::tr{'delete'}) } close FILE; } else { - $errormessage = "Can't umount $extrahdsettings{'PATH'}. Maybe the device is in use?"; + $errormessage = "$Lang::tr{'extrahd cant umount'} $extrahdsettings{'PATH'}$Lang::tr{'extrahd maybe the device is in use'}?"; } } @@ -143,10 +143,10 @@ END $color=$Header::colourgreen; } print <  - $deviceline[0] - $deviceline[1] - $deviceline[2] +   + $deviceline[0] + $deviceline[1] + $deviceline[2]
@@ -154,7 +154,7 @@ END -
+ END ; } @@ -179,21 +179,26 @@ END foreach $scanentry (sort @scans) { @scanline = split( /\;/, $scanentry ); - print <  - /dev/$scanline[0] - $scanline[1] + # remove wrong entries like usb controller name + if ($scanline[1] ne "\n") + { + print <  + /dev/$scanline[0] + $scanline[1] END ; + + } foreach $partitionentry (sort @partitions) { @partitionline = split( /\;/, $partitionentry ); if ( "$partitionline[0]" eq "$scanline[0]" ) { $size = int($partitionline[1] / 1024); print <$Lang::tr{'size'} $size MB -   -   + $Lang::tr{'size'} $size MB +   +   END ; } @@ -202,28 +207,31 @@ END foreach $partitionentry (sort @partitions) { @partitionline = split( /\;/, $partitionentry ); - if (( "$partitionline[0]" =~ /^$scanline[0]/ ) && !( "$partitionline[2]" eq "" )) { + if (( "$partitionline[0]" =~ /^$scanline[0]/ ) && ! ( "$partitionline[0]" eq "$scanline[0]" )) { $size = int($partitionline[1] / 1024); print < - UUID=$partitionline[2] + UUID=$partitionline[2] /dev/$partitionline[0] - $Lang::tr{'size'} $size MB + $Lang::tr{'size'} $size MB - + + - + +END +; END ; @@ -232,7 +240,9 @@ END } print <If your device isn't listed here, you need to install or load the driver.
If you can see your device but no partitions you have to create them first. +   +   + $Lang::tr{'extrahd install or load driver'} END ; From ddb6262fe588a487f61c8565b399f480b46932ce Mon Sep 17 00:00:00 2001 From: Jan Paul Tuecking Date: Fri, 27 May 2011 14:03:08 +0200 Subject: [PATCH 2/4] extrahd.cgi: insert new translation strings. --- langs/de/cgi-bin/de.pl | 9 +++++++++ langs/en/cgi-bin/en.pl | 9 +++++++++ langs/es/cgi-bin/es.pl | 9 +++++++++ langs/fr/cgi-bin/fr.pl | 9 +++++++++ 4 files changed, 36 insertions(+) diff --git a/langs/de/cgi-bin/de.pl b/langs/de/cgi-bin/de.pl index b78efc5da..81cc3ee5c 100644 --- a/langs/de/cgi-bin/de.pl +++ b/langs/de/cgi-bin/de.pl @@ -775,6 +775,15 @@ 'external aliases configuration' => 'Externe Alias-Konfiguration', 'extrahd' => 'ExtraHD', 'extrahd detected drives' => 'gefundene Laufwerke', +'extrahd unable to read' => 'Lesefehler von', +'extrahd unable to write' => 'Schreibfehler von', +'extrahd you cant mount' => 'Sie können', +'extrahd to' => 'nicht nach', +'extrahd to root' => 'nicht nach root mounten', +'extrahd because there is already a device mounted' => ' mounten, weil bereits ein Geräte gemountet ist', +'extrahd cant umount' => 'Konnte', +'extrahd maybe the device is in use' => 'nicht mounten. Vielleicht wird das Gerät bereits verwendet', +'extrahd install or load driver' => 'Wenn Ihre Festplatte nicht angezeigt wird, müssen Sie zuerst den Treiber laden oder ggf. auch nach installieren. Wenn diese jedoch angezeigt wird, aber keine Partitionen zu sehen sind, müssen diese erst angelegt werden.', 'false classnumber' => 'Die Klassennummer passt nicht zum angegebenen Interface.', 'false max bandwith' => 'Maximalbandbreite ist ungültig.', 'false min bandwith' => 'Mindestbandbreite ist ungültig.', diff --git a/langs/en/cgi-bin/en.pl b/langs/en/cgi-bin/en.pl index 20a2681da..ad48b4a36 100644 --- a/langs/en/cgi-bin/en.pl +++ b/langs/en/cgi-bin/en.pl @@ -799,6 +799,15 @@ 'external aliases configuration' => 'External aliases configuration', 'extrahd' => 'ExtraHD', 'extrahd detected drives' => 'detected drives', +'extrahd unable to read' => 'Unable to read', +'extrahd unable to write' => 'Unable to write', +'extrahd you cant mount' => 'You can\'t mount', +'extrahd to' => 'to', +'extrahd to root' => 'to root', +'extrahd because there is already a device mounted' => ', because there is already a device mounted', +'extrahd cant umount' => 'Can\'t umount', +'extrahd maybe the device is in use' => '. Maybe the device is in use', +'extrahd install or load driver' => 'If your device isn\'t listed here, you need to install or load the driver.
If you can see your device but no partitions you have to create them first.', 'false classnumber' => 'The Class-Number does not match the interface.', 'false max bandwith' => 'Maximum bandwith is false.', 'false min bandwith' => 'Minimum bandwith is false.', diff --git a/langs/es/cgi-bin/es.pl b/langs/es/cgi-bin/es.pl index e35c680b9..1b3c62f98 100644 --- a/langs/es/cgi-bin/es.pl +++ b/langs/es/cgi-bin/es.pl @@ -797,6 +797,15 @@ 'external aliases configuration' => 'Configuración de Alias externo', 'extrahd' => 'Disco duro Adicional', 'extrahd detected drives' => 'Unidades encontradas', +'extrahd unable to read' => 'Unable to read', +'extrahd unable to write' => 'Unable to write', +'extrahd you cant mount' => 'You can\'t mount', +'extrahd to' => 'to', +'extrahd to root' => 'to root', +'extrahd because there is already a device mounted' => ', because there is already a device mounted', +'extrahd cant umount' => 'Can\'t umount', +'extrahd maybe the device is in use' => '. Maybe the device is in use', +'extrahd install or load driver' => 'If your device isn\'t listed here, you need to install or load the driver.
If you can see your device but no partitions you have to create them first.', 'false classnumber' => 'El número de clase no coincide con la interfaz', 'false max bandwith' => 'El ancho de banda máximo es falso', 'false min bandwith' => 'El ancho de banda mínimo es falso', diff --git a/langs/fr/cgi-bin/fr.pl b/langs/fr/cgi-bin/fr.pl index 8d52e1d36..f2069378d 100644 --- a/langs/fr/cgi-bin/fr.pl +++ b/langs/fr/cgi-bin/fr.pl @@ -798,6 +798,15 @@ 'external aliases configuration' => 'Configuration des alias externes', 'extrahd' => 'ExtraHD', 'extrahd founded drives' => 'Périphériques trouvés', +'extrahd unable to read' => 'Unable to read', +'extrahd unable to write' => 'Unable to write', +'extrahd you cant mount' => 'You can\'t mount', +'extrahd to' => 'to', +'extrahd to root' => 'to root', +'extrahd because there is already a device mounted' => ', because there is already a device mounted', +'extrahd cant umount' => 'Can\'t umount', +'extrahd maybe the device is in use' => '. Maybe the device is in use', +'extrahd install or load driver' => 'If your device isn\'t listed here, you need to install or load the driver.
If you can see your device but no partitions you have to create them first.', 'false classnumber' => 'Le numéro de classe ne correspond pas à l\'interface.', 'false max bandwith' => 'La bande passante maximum est fausse.', 'false min bandwith' => 'La bande passante minimum est fausse.', From 156337976b33ca58a94b6a4fbb03bae7f1b9b38b Mon Sep 17 00:00:00 2001 From: Jan Paul Tuecking Date: Mon, 30 May 2011 18:14:42 +0200 Subject: [PATCH 3/4] extrahd.cgi: French translation. Thx Lalsacien! --- langs/fr/cgi-bin/fr.pl | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/langs/fr/cgi-bin/fr.pl b/langs/fr/cgi-bin/fr.pl index f2069378d..c2ac5b4b4 100644 --- a/langs/fr/cgi-bin/fr.pl +++ b/langs/fr/cgi-bin/fr.pl @@ -797,16 +797,16 @@ 'external access rule removed' => 'Règle d\'accès externe supprimée; redémarrage du controleur d\'accès', 'external aliases configuration' => 'Configuration des alias externes', 'extrahd' => 'ExtraHD', -'extrahd founded drives' => 'Périphériques trouvés', -'extrahd unable to read' => 'Unable to read', -'extrahd unable to write' => 'Unable to write', -'extrahd you cant mount' => 'You can\'t mount', -'extrahd to' => 'to', -'extrahd to root' => 'to root', -'extrahd because there is already a device mounted' => ', because there is already a device mounted', -'extrahd cant umount' => 'Can\'t umount', -'extrahd maybe the device is in use' => '. Maybe the device is in use', -'extrahd install or load driver' => 'If your device isn\'t listed here, you need to install or load the driver.
If you can see your device but no partitions you have to create them first.', +'extrahd detected drives' => 'Périphériques trouvés', +'extrahd unable to read' => 'Impossible de lire', +'extrahd unable to write' => 'Impossible d\'écrire', +'extrahd you cant mount' => 'Vous ne pouvez pas monter', +'extrahd to' => 'vers', +'extrahd to root' => 'vers root', +'extrahd because there is already a device mounted' => ' car vous avez déjà un support de monté', +'extrahd cant umount' => 'Impossible de démonter', +'extrahd maybe the device is in use' => '. Votre support est peut-être en cours d\'utilisation', +'extrahd install or load driver' => 'Si votre support n\'est pas visible ici, vous devez installer ou charger son pilote.
Si vous voyez votre support mais pas de partitions, vous devez tout d\'abord les créer.', 'false classnumber' => 'Le numéro de classe ne correspond pas à l\'interface.', 'false max bandwith' => 'La bande passante maximum est fausse.', 'false min bandwith' => 'La bande passante minimum est fausse.', From 1eaa29b151b6b923041e612f7f0c588b44dbdbeb Mon Sep 17 00:00:00 2001 From: Jan Paul Tuecking Date: Tue, 31 May 2011 23:02:23 +0200 Subject: [PATCH 4/4] extrahd.cgi: added again display also non-partitioned disks from Arne. --- html/cgi-bin/extrahd.cgi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/html/cgi-bin/extrahd.cgi b/html/cgi-bin/extrahd.cgi index 7cdad0161..86b0de5c3 100644 --- a/html/cgi-bin/extrahd.cgi +++ b/html/cgi-bin/extrahd.cgi @@ -207,7 +207,7 @@ END foreach $partitionentry (sort @partitions) { @partitionline = split( /\;/, $partitionentry ); - if (( "$partitionline[0]" =~ /^$scanline[0]/ ) && ! ( "$partitionline[0]" eq "$scanline[0]" )) { + if (( "$partitionline[0]" =~ /^$scanline[0]/ ) && !( "$partitionline[2]" eq "" )) { $size = int($partitionline[1] / 1024); print <