--- search/Search.cgi 2002/06/24 14:50:44 1.6
+++ search/Search.cgi 2002/06/24 16:49:54 1.8
@@ -2689,6 +2689,9 @@
if ( $HTML ) {
print("\n");
#print("
$SelectorText | $Score | $Headline ( $main::DatabaseDescriptions{$Database} ) ");
+ # decode some basic html from headline
+ $Headline =~ s/<(\/?[bi])>/<$1>/g;
+
print(" $SelectorText | $Headline ");
} else {
printf("%3d $Headline ($main::DatabaseDescriptions{$Database})\n", $Score);
@@ -3102,7 +3105,13 @@
# Database selection
if ( %main::DatabaseDescriptions ) {
- print(" Odaberite bazu koju želite pretraživati: | |
+ print(" | Odaberite bazu koju želite pretraživati:
+ |
+ Označi
+ sve,
+ niti jednu.
+
+ | |
");
# Parse out the database names and put them into a
@@ -3117,56 +3126,8 @@
@ItemList = split(",", $SelectedDatabases);
}
}
- foreach $ItemEntry ( @ItemList ) {
- $Value{$ItemEntry} = $ItemEntry;
- }
-
-
- $Flag = 0;
-
- print('
- all
- none
- ');
-
- print("\n");
+ &ShowDatabaseCheckBoxes(@ItemList);
print(" |
\n");
@@ -4148,40 +4109,16 @@
print(" Odabrane baze: |
\n");
- print(" Označite baze koje uvijek želite pretraživati: | \n");
+ print(" |
Označite baze koje uvijek želite pretraživati: | \n");
# Parse out the database names and put them into a
# hash table, they should be separated with a '\n'
- undef(%Value);
if ( defined($SelectedDatabases) && ($SelectedDatabases ne "") ) {
@ItemList = split(",", $SelectedDatabases);
- foreach $ItemEntry ( @ItemList ) {
- $Value{$ItemEntry} = $ItemEntry;
- }
}
-
- $Flag = 0;
- print("\n");
+
+ &ShowDatabaseCheckBoxes(@ItemList);
+
print(" |
\n");
}
@@ -7488,3 +7425,56 @@
}
}
}
+
+#--------------------------------------------------------------------------
+# show list of all databases
+#
+# usage: ShowDatabaseCheckBoxes(@SelectedDatabases)
+
+sub ShowDatabaseCheckBoxes {
+ # Parse out the database names and put them into a
+ # hash table, they should be separated with a '\0'
+ my %Value;
+
+ foreach my $ItemEntry ( @_ ) {
+ $Value{$ItemEntry} = $ItemEntry;
+ }
+
+ print("\n");
+}