/[swish]/trunk/spider/progspider
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/spider/progspider

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

revision 81 by dpavlin, Sat Aug 28 22:15:59 2004 UTC revision 84 by dpavlin, Sun Aug 29 21:19:13 2004 UTC
# Line 78  sub file { Line 78  sub file {
78    
79                  return if (! $html);                  return if (! $html);
80    
81                    my $file_only = $path;
82                    $file_only =~ s/^.*\/([^\/]+)$/$1/g;
83    
84                  my ($pre_html,$pages,$post_html) = ('<html><head><title>$path :: page ##page_nr##</title></head><body><pre>',$html,'</pre></body></html>');                  my ($pre_html,$pages,$post_html) = ('<html><head><title>$path :: page ##page_nr##</title></head><body><pre>',$html,'</pre></body></html>');
85    
86                  ($pre_html,$pages,$post_html) = ($1,$2,$3) if ($html =~ m/^(<html>.+?<pre>)(.+)(<\/pre>.+?)$/si);                  ($pre_html,$pages,$post_html) = ($1,$2,$3) if ($html =~ m/^(<html>.+?<pre>)(.+)(<\/pre>.+?)$/si);
# Line 85  sub file { Line 88  sub file {
88                  if ($collection) {                  if ($collection) {
89                          $pre_html =~ s/<title>(.+?)<\/title>/<title>$collection :: page ##page_nr##<\/title>/si;                          $pre_html =~ s/<title>(.+?)<\/title>/<title>$collection :: page ##page_nr##<\/title>/si;
90                  } else {                  } else {
91                          $pre_html =~ s/<title>(.+?)<\/title>/<title>$1 :: page ##page_nr##<\/title>/si;                          $pre_html =~ s/<title>(.+?)<\/title>/<title>$1 :: page ##page_nr##<\/title>/si ||
92                            $pre_html =~ s/<title><\/title>/<title>$file_only :: page ##page_nr##<\/title>/si;
93                  }                  }
94    
95                  my $page_nr = 1;                  my $page_nr = 1;

Legend:
Removed from v.81  
changed lines
  Added in v.84

  ViewVC Help
Powered by ViewVC 1.1.26