/[webpac2]/trunk/lib/WebPAC/Output/SWISH.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /trunk/lib/WebPAC/Output/SWISH.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1165 by dpavlin, Sat Apr 25 17:11:33 2009 UTC revision 1179 by dpavlin, Wed Apr 29 18:14:17 2009 UTC
# Line 18  use File::Path qw/mkpath/; Line 18  use File::Path qw/mkpath/;
18  use Data::Dump qw/dump/;  use Data::Dump qw/dump/;
19  use YAML;  use YAML;
20  use JSON;  use JSON;
21    use Encode qw/encode/;
22    
23    
24  =head1 NAME  =head1 NAME
# Line 151  sub add { Line 152  sub add {
152          return unless (@tags);          return unless (@tags);
153    
154          my $xml = qq{<all>};          my $xml = qq{<all>};
   
         $xml .= "<$_>" . $self->$_ . "</$_>" foreach ( 'database', 'input' );  
   
155          my $data;          my $data;
156    
157            foreach ( 'database', 'input' ) {
158                    $xml .= "<$_>" . $self->$_ . "</$_>";
159                    $data->{$_} = $self->$_;
160            }
161    
162          foreach my $tag (@tags) {          foreach my $tag (@tags) {
163    
164                  my $r = ref $ds->{$tag}->{$type};                  my $r = ref $ds->{$tag}->{$type};
# Line 181  sub add { Line 184  sub add {
184    
185          $xml .= qq{</all>\n};          $xml .= qq{</all>\n};
186    
187            $xml = encode('utf-8', $xml);
188    
189          my $len = length($xml);          my $len = length($xml);
190    
191          my $fh = $self->{_swish_fh} || die "_swish_fh missing";          my $fh = $self->{_swish_fh} || die "_swish_fh missing";

Legend:
Removed from v.1165  
changed lines
  Added in v.1179

  ViewVC Help
Powered by ViewVC 1.1.26