bagder: curl-www/docs faqparse.pl,1.3,1.4
| Newsgroups | gmane.comp.web.curl.www.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/curl/curl-www/docs
In directory labb.contactor.se:/tmp/cvs-serv23305
Modified Files:
faqparse.pl
Log Message:
nicer subtitles too, no newline no surrouding spaces
Index: faqparse.pl
===================================================================
RCS file: /cvsroot/curl/curl-www/docs/faqparse.pl,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- faqparse.pl 25 Nov 2004 14:18:17 -0000 1.3
+++ faqparse.pl 25 Nov 2004 14:21:45 -0000 1.4
@@ -28,7 +28,10 @@
$s = $_;
$s =~ s/^([0-9]).*/$1/g;
if($s != $o) {
- subtitle(sprintf "%s", $section[$s]);
+ my $ti = $section[$s];
+ chomp $ti;
+ $ti =~ s/^ *(.*) */$1/;
+ subtitle($ti);
print "\n<p>\n";
$o = $s;
}
@@ -56,7 +59,11 @@
if($secs[$sec] && ($_ =~ /^\s*[0-9]\. $secs[$sec]/i)) {
# a new section
- subtitle($l);
+ my $ti = $l;
+ chomp $ti;
+ $ti =~ s/^ *(.*) */$1/;
+ subtitle($ti);
+
$sec++;
}
_______________________________________________
http://cool.haxx.se/mailman/listinfo/curl-www-commits