summaryrefslogtreecommitdiff
path: root/www/txt2plain.pl
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2002-08-21 11:19:20 +0000
committerDaniel Stenberg <daniel@haxx.se>2002-08-21 11:19:20 +0000
commite62f191dcfb2d4dbcd4c12b97673b276d6f661ef (patch)
treecd7fe3f8a909903301b60e5af1823cc3e2f1724b /www/txt2plain.pl
parent057b85a57bebd74a17104a632c5e7ba4d9c671f2 (diff)
downloadrockbox-e62f191dcfb2d4dbcd4c12b97673b276d6f661ef.tar.gz
rockbox-e62f191dcfb2d4dbcd4c12b97673b276d6f661ef.zip
minor improvements
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@1874 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'www/txt2plain.pl')
-rwxr-xr-xwww/txt2plain.pl6
1 files changed, 3 insertions, 3 deletions
diff --git a/www/txt2plain.pl b/www/txt2plain.pl
index 72640522b6..287e8787d8 100755
--- a/www/txt2plain.pl
+++ b/www/txt2plain.pl
@@ -8,7 +8,7 @@ sub fixline {
8 8
9 $_ =~ s/(http:\/\/([a-zA-Z0-9_.\/-]*)[^\) .\n])/\<a href=\"$1\"\>$1\<\/a\>/g; 9 $_ =~ s/(http:\/\/([a-zA-Z0-9_.\/-]*)[^\) .\n])/\<a href=\"$1\"\>$1\<\/a\>/g;
10 10
11 $_ =~ s/^$/\&nbsp;/g; # empty lines are nbsp 11 $_ =~ s/^\s*$/\&nbsp;\n/g; # empty lines are nbsp
12 $_ =~ s/(\\|\/)$/$1&nbsp;/g; # clobber backslash on end of line 12 $_ =~ s/(\\|\/)$/$1&nbsp;/g; # clobber backslash on end of line
13} 13}
14 14
@@ -18,7 +18,7 @@ while(<STDIN>) {
18 18
19 # detect and mark Q-sections 19 # detect and mark Q-sections
20 if( $_ =~ /^Q(\d*)/) { 20 if( $_ =~ /^Q(\d*)/) {
21 print "</pre>\n<a name=\"$1\"></a><p class=\"faqq\">$_"; 21 print "</pre>\n<a name=\"$1\"></a><div class=\"faqq\">$_";
22 my $line; 22 my $line;
23 while(<STDIN>) { 23 while(<STDIN>) {
24 24
@@ -32,7 +32,7 @@ while(<STDIN>) {
32 last; 32 last;
33 } 33 }
34 } 34 }
35 print "</p>\n<pre class=\"faqa\">\n$line"; 35 print "</div>\n<pre class=\"faqa\">$line";
36 next; 36 next;
37 } 37 }
38 38