--- loncom/interface/lonsearchcat.pm 2011/02/15 14:54:51 1.329 +++ loncom/interface/lonsearchcat.pm 2012/05/25 22:40:43 1.331.4.2 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Search Catalog # -# $Id: lonsearchcat.pm,v 1.329 2011/02/15 14:54:51 wenzelju Exp $ +# $Id: lonsearchcat.pm,v 1.331.4.2 2012/05/25 22:40:43 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -152,7 +152,8 @@ sub handler { ## Initialize global variables ## my $domain = $r->dir_config('lonDefDomain'); - $diropendb= "/home/httpd/perl/tmp/". + my $temp_file_dir = LONCAPA::tempdir(); + $diropendb= $temp_file_dir . "$env{'user.domain'}_$env{'user.name'}_sel_res.db"; # # set the name of the persistent database @@ -163,7 +164,7 @@ sub handler { $env{'form.persistent_db_id'} = time; } - my $persistent_db_file = "/home/httpd/perl/tmp/". + my $persistent_db_file = $temp_file_dir . &escape($domain). '_'.&escape($env{'user.name'}). '_'.$env{'form.persistent_db_id'}.'_persistent_search.db'; @@ -2383,7 +2384,10 @@ END next; } $status=~s|/||g; - my $datafile=$r->dir_config('lonDaemons').'/tmp/'.$status; + + + + my $datafile=LONCAPA::tempdir().$status; if (-e $datafile && ! -e "$datafile.end") { &update_status($r,&mt('Receiving results from [_1]',$server)); next; @@ -3059,22 +3063,9 @@ SCRIPT SCRIPT - - # Add JavaScript-function to set link for a ressource to wishlist - $js.=< -// - -SCRIPT - my $start_page = &Apache::loncommon::start_page(undef,$js, - {'only_body' =>1}); + {'only_body' =>1, + 'add_wishlist' =>1}); my $result=<