--- loncom/interface/lonsearchcat.pm 2002/06/24 16:45:22 1.128 +++ loncom/interface/lonsearchcat.pm 2002/06/25 15:08:59 1.129 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Search Catalog # -# $Id: lonsearchcat.pm,v 1.128 2002/06/24 16:45:22 harris41 Exp $ +# $Id: lonsearchcat.pm,v 1.129 2002/06/25 15:08:59 matthew Exp $ # # Copyright Michigan State University Board of Trustees # @@ -273,7 +273,8 @@ sub basic_search_form{ $hidden

Basic Search

-Enter terms or phrases separated by AND, OR, or NOT then press SEARCH below. +Enter terms or quoted phrases separated by AND, OR, or NOT +then press SEARCH below.

@@ -322,6 +323,23 @@ Returns a scalar which holds html for th sub advanced_search_form{ my ($closebutton,$hidden) = @_; + my $advanced_buttons = <<"END"; +

+ + +$closebutton + + + + +

+END my $scrout=<<"ENDHEADER"; @@ -336,34 +354,44 @@ sub advanced_search_form{ -

Search Catalog

- -$hidden +

Advanced Catalog Search


-

Advanced Search

+Enter terms or quoted phrases separated by search operators +such as AND, OR, or NOT.
+$advanced_buttons +$hidden +
ENDHEADER - $scrout.=&searchphrasefield('Limit by title','title', + $scrout.=&searchphrasefield('title','title', $ENV{'form.title'}); - $scrout.=&searchphrasefield('Limit by author','author', + $scrout.=&searchphrasefield('author','author', $ENV{'form.author'}); - $scrout.=&searchphrasefield('Limit by subject','subject', + $scrout.=&searchphrasefield('subject','subject', $ENV{'form.subject'}); - $scrout.=&searchphrasefield('Limit by keywords','keywords', + $scrout.=&searchphrasefield('keywords','keywords', $ENV{'form.keywords'}); - $scrout.=&searchphrasefield('Limit by URL','url', + $scrout.=&searchphrasefield('URL','url', $ENV{'form.url'}); # $scrout.=&searchphrasefield('Limit by version','version', # $ENV{'form.version'}); - $scrout.=&searchphrasefield('Limit by notes','notes', + $scrout.=&searchphrasefield('notes','notes', $ENV{'form.notes'}); - $scrout.=&searchphrasefield('Limit by abstract','abstract', + $scrout.=&searchphrasefield('abstract','abstract', $ENV{'form.abstract'}); - $ENV{'form.mime'}='any' unless length($ENV{'form.mime'}); - $scrout.=&selectbox('Limit by MIME type','mime', - $ENV{'form.mime'}, - 'any','Any type', - \&{Apache::loncommon::filedescriptionex}, - (&Apache::loncommon::fileextensions)); + # Hack - an empty table row. + $scrout.="\n"; + $scrout.=&searchphrasefield('file
extension','mime', + $ENV{'form.mime'}); + $scrout.="\n"; + $scrout.=&searchphrasefield('publisher
owner','owner', + $ENV{'form.owner'}); + $scrout.="
  
  
\n"; +# $ENV{'form.mime'}='any' unless length($ENV{'form.mime'}); +# $scrout.=&selectbox('Limit by MIME type','mime', +# $ENV{'form.mime'}, +# 'any','Any type', +# \&{Apache::loncommon::filedescriptionex}, +# (&Apache::loncommon::fileextensions)); $ENV{'form.language'}='any' unless length($ENV{'form.language'}); $scrout.=&selectbox('Limit by language','language', $ENV{'form.language'},'any','Any Language', @@ -410,8 +438,6 @@ LASTREVISIONDATEEND $ENV{'form.lastrevisiondateend_year'}, ); $scrout.='

'; - $scrout.=&searchphrasefield('Limit by publisher/owner','owner', - $ENV{'form.owner'}); $ENV{'form.copyright'}='any' unless length($ENV{'form.copyright'}); $scrout.=&selectbox('Limit by copyright/distribution','copyright', $ENV{'form.copyright'}, @@ -440,21 +466,7 @@ in a fielded listing for each record res CUSTOMSHOW $scrout.=&simpletextfield('customshow',$ENV{'form.customshow'}); $scrout.=< - - -$closebutton - - - - -

+$advanced_buttons @@ -534,7 +546,46 @@ the day, month, and year. =item &selectbox() -Returns html selection form. +Returns a scalar containing an html tag. + +=item $default + +The default value of the form. Can be $anyvalue or in @idlist. + +=item $anyvalue + +The