--- search/Search.cgi 2002/06/24 17:53:11 1.10 +++ search/Search.cgi 2002/06/25 15:59:51 1.15 @@ -232,25 +232,6 @@ $main::QueryReportMimeType = "application/x-wais-report"; - -# Hash of icon/images names that we use -%main::ImageNames = ( - 'banner', 'banner.gif', - 'collapse', 'collapse.gif', - 'expand', 'expand.gif', - 'inactive-search', 'inactive-search.gif', - 'active-search', 'active-search.gif', - 'inactive-search-history', 'inactive-search-history.gif', - 'active-search-history', 'active-search-history.gif', - 'inactive-saved-searches', 'inactive-saved-searches.gif', - 'active-saved-searches', 'active-saved-searches.gif', - 'inactive-document-folders','inactive-document-folders.gif', - 'active-document-folders', 'active-document-folders.gif', - 'inactive-settings', 'inactive-settings.gif', - 'active-settings', 'active-settings.gif', -); - - # Array of mime type names, we use this to map # mime types to mime type names (which are more readable) %main::MimeTypeNames = ( @@ -411,6 +392,7 @@ print("$JavaScript\n"); } print ''; + print ''; print("\n\n"); @@ -521,47 +503,23 @@ } } - if ( %MenuBar && defined($MenuBar{'GetSearch'}) ) { - print("\"Search\""); - - - } - else { - - print(""); - - + my $DISABLED; - } + $DISABLED = ( %MenuBar && defined($MenuBar{'GetSearch'}) ) ? "DISABLED" : ""; + print(""); if ( defined($main::RemoteUser) ) { - if ( %MenuBar && defined($MenuBar{'ListSearchHistory'}) ) { - print("\"Search"); - } - else { - print(""); - } + $DISABLED = ( %MenuBar && defined($MenuBar{'ListSearchHistory'}) ) ? "DISABLED" : ""; + print""; - if ( %MenuBar && defined($MenuBar{'ListSavedSearch'}) ) { - print("\"Saved"); - } - else { - print(""); - } + $DISABLED = ( %MenuBar && defined($MenuBar{'ListSavedSearch'}) ) ? "DISABLED" : ""; + print""; - if ( %MenuBar && defined($MenuBar{'ListFolder'}) ) { - print("\"Doument"); - } - else { - print(""); - } - - if ( %MenuBar && defined($MenuBar{'GetUserSettings'}) ) { - print("\"My"); - } - else { - print(""); - } + $DISABLED = ( %MenuBar && defined($MenuBar{'ListFolder'}) ) ? "DISABLED" : ""; + print""; + + $DISABLED = ( %MenuBar && defined($MenuBar{'GetUserSettings'}) ) ? "DISABLED" : ""; + print""; } @@ -1571,6 +1529,8 @@ # nuke accented chars $SearchString =~ tr/Çüéâäùæç³ëÕõî¬ÄÆÉÅåôö¥µ¦¶ÖÜ«»£èáíóú¡±®¾Êê¼ÈºÁÂ̪¯¿ÃãðÐÏËïÒÍÎìÞÙÓÔÑñò©¹ÀÚàÛýÝþ´­½²·¢¸¨ÿØø/CueaauccleOoiZACELlooLlSsOUTtLcaiouAaZzEezCsAAESZzAadDDEdNIIeTUOoNnnSsRUrUyYt'-".'',"'Rr/; + # convert search string to lower case -> make search case insensitive + $SearchString =~ tr/A-Z/a-z/; # Add the internal search terms @@ -2973,23 +2933,8 @@ # Make sure that we send the header $Value = ($ENV{'PATH_INFO'} eq "/GetExpandedSearch") ? "Pretra¾ivanje s vi¹e kriterija" : "Jednostavno pretra¾ivanje"; - my $JavaScript = ' - '; - &vSendHTMLHeader($Value, $JavaScript); + &vSendHTMLHeader($Value, $main::JavaScript_SetChecked); undef(%Value); $Value{'GetSearch'} = "GetSearch"; @@ -3104,13 +3049,8 @@ # Database selection if ( %main::DatabaseDescriptions ) { - print(" Odaberite bazu koju ¾elite pretra¾ivati: - - Oznaèi - sve, - niti jednu. - - + print(" Odaberite bazu koju ¾elite pretra¾ivati: + "); # Parse out the database names and put them into a @@ -4011,7 +3951,7 @@ # Make sure that we send the header - &vSendHTMLHeader("My Settings", undef); + &vSendHTMLHeader("My Settings", $main::JavaScript_SetChecked); undef(%Value); $Value{'GetUserSettings'} = "GetUserSettings"; &vSendMenuBar(%Value); @@ -4049,7 +3989,7 @@ print("

Postavke:

\n"); print("\n"); - print("\n"); + print("\n"); # Send the buttons print("\n"); @@ -4111,14 +4051,14 @@ print("\n"); - print("\n"); @@ -4264,7 +4204,7 @@ $Value{'UserName'} = $main::FormData{'UserName'}; $Value{'EmailAddress'} = $main::FormData{'EmailAddress'}; $Value{'DefaultSearch'} = $main::FormData{'DefaultSearch'}; - $Value{'SelectedDatabases'} = $main::FormData{'SelectedDatabases'}; + $Value{'SelectedDatabases'} = $main::FormData{'Database'}; if ( defined($Value{'SelectedDatabases'}) ) { $Value{'SelectedDatabases'} =~ s/\0/,/g; } @@ -7158,34 +7098,34 @@ } - if ( defined($main::FormData{'GetSearch.x'}) ) { + if ( defined($main::FormData{'GetSearch'}) ) { $ENV{'PATH_INFO'} = "/GetSearch"; - delete($main::FormData{'GetSearch.x'}); - delete($main::FormData{'GetSearch.y'}); + delete($main::FormData{'GetSearch'}); + delete($main::FormData{'GetSearch'}); } - if ( defined($main::FormData{'ListSearchHistory.x'}) ) { + if ( defined($main::FormData{'ListSearchHistory'}) ) { $ENV{'PATH_INFO'} = "/ListSearchHistory"; - delete($main::FormData{'ListSearchHistory.x'}); - delete($main::FormData{'ListSearchHistory.y'}); + delete($main::FormData{'ListSearchHistory'}); + delete($main::FormData{'ListSearchHistory'}); } - if ( defined($main::FormData{'ListSavedSearch.x'}) ) { + if ( defined($main::FormData{'ListSavedSearch'}) ) { $ENV{'PATH_INFO'} = "/ListSavedSearch"; - delete($main::FormData{'ListSavedSearch.x'}); - delete($main::FormData{'ListSavedSearch.y'}); + delete($main::FormData{'ListSavedSearch'}); + delete($main::FormData{'ListSavedSearch'}); } - if ( defined($main::FormData{'ListFolder.x'}) ) { + if ( defined($main::FormData{'ListFolder'}) ) { $ENV{'PATH_INFO'} = "/ListFolder"; - delete($main::FormData{'ListFolder.x'}); - delete($main::FormData{'ListFolder.y'}); + delete($main::FormData{'ListFolder'}); + delete($main::FormData{'ListFolder'}); } - if ( defined($main::FormData{'GetUserSettings.x'}) ) { + if ( defined($main::FormData{'GetUserSettings'}) ) { $ENV{'PATH_INFO'} = "/GetUserSettings"; - delete($main::FormData{'GetUserSettings.x'}); - delete($main::FormData{'GetUserSettings.y'}); + delete($main::FormData{'GetUserSettings'}); + delete($main::FormData{'GetUserSettings'}); } @@ -7443,6 +7383,12 @@ } print("
Odabrane baze:
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' if ( defined($SelectedDatabases) && ($SelectedDatabases ne "") ) { @ItemList = split(",", $SelectedDatabases); } - + &ShowDatabaseCheckBoxes(@ItemList); print("
\n"); + print ""; my @html_database;
+ Oznaèi + sve, + niti jednu. + +