[Koha-cvs] CVS: koha/opac opac-main.pl,1.13,1.14 opac-search.pl,1.17,1.18

Paul POULAIN tipaul at users.sourceforge.net
Mon Aug 16 14:48:55 CEST 2004


Update of /cvsroot/koha/koha/opac
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv434/opac

Modified Files:
	opac-main.pl opac-search.pl 
Log Message:
moving language chooser to the main page.
monving the getalltemplates and getalllanguages subs out from Search.pm (that will be deprecated soon) to Koha.pm

Index: opac-main.pl
===================================================================
RCS file: /cvsroot/koha/koha/opac/opac-main.pl,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -r1.13 -r1.14
*** opac-main.pl	17 Jun 2004 08:24:50 -0000	1.13
--- opac-main.pl	16 Aug 2004 12:48:53 -0000	1.14
***************
*** 8,11 ****
--- 8,12 ----
  use C4::Interface::CGI::Output;
  use C4::BookShelves;
+ use C4::Koha;
  
  my $input = new CGI;
***************
*** 35,41 ****
--- 36,53 ----
  			     flagsrequired => {borrow => 1},
  			 });
+ my @options;
+ my $counter=0;
+ foreach my $language (getalllanguages()) {
+ 	next if $language eq 'images';
+ 	my $selected='0';
+ #                            next if $currently_selected_languages->{$language};
+ 	push @options, { language => $language, counter => $counter };
+ 	$counter++;
+ }
+ 
  $template->param(CGIitemtype => $CGIitemtype,
  				suggestion => C4::Context->preference("suggestion"),
  				virtualshelves => C4::Context->preference("virtualshelves"),
+ 				languages => \@options,
  );
  output_html_with_http_headers $input, $cookie, $template->output;

Index: opac-search.pl
===================================================================
RCS file: /cvsroot/koha/koha/opac/opac-search.pl,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -r1.17 -r1.18
*** opac-search.pl	15 Aug 2004 01:50:24 -0000	1.17
--- opac-search.pl	16 Aug 2004 12:48:53 -0000	1.18
***************
*** 176,193 ****
  				-multiple => 0 );
  	$sth->finish;
-         my @options;
-     my $counter=0;
-         foreach my $language (getalllanguages()) {
-                             next if $language eq 'images';
-                             my $selected='0';
- #                            next if $currently_selected_languages->{$language};
-                             push @options, { language => $language, counter => $counter };
-                             $counter++;
-                     }
      
  	$template->param(classlist => $classlist,
  					CGIitemtype => $CGIitemtype,
  					CGIbranch => $CGIbranch,
- 	                                languages => \@options,
  	);
  }
--- 176,183 ----





More information about the Koha-cvs mailing list