Changeset 6958 in genesis
- Timestamp:
- Jun 10, 2009, 8:55:21 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified tools/FreeBSD7_x/g_list.pl ¶
r6664 r6958 12 12 13 13 my $HTML=1; 14 my @HTTP_BODY = (); 14 15 15 16 #laden van tool file … … 19 20 #programma gestopt kan worden 20 21 sub printline { 21 p rint "$_[0] \n";22 push(@HTTP_BODY, "$_[0] \n"); 22 23 }; 23 24 … … 25 26 foreach $file ( sort @filelist) { 26 27 if( $HTML) { 27 print "$file<BR>\n";28 printline("$file<BR>"); 28 29 } 29 30 else { 30 print "$file\n";31 printline($file); 31 32 }; 32 33 }; … … 53 54 foreach $node (listnodes( )) { 54 55 if( $HTML) { 55 print "$node<BR>\n";56 printline("$node<BR>"); 56 57 } 57 58 else { 58 print "$node\n";59 printline("$node\n"); 59 60 }; 60 61 }; … … 79 80 if( $browser=~/curl|wget|fetch/i) { 80 81 $HTML=0; 81 printline("Content-type: text/html\n\n");82 82 } 83 83 else { 84 84 $HTML=1; 85 printline("Content-type: text/html\n\n");86 85 printline("<HTML>"); 87 86 printline("<TITLE>Genesis $title</TITLE>"); … … 131 130 #plaats de sluit HTML tags 132 131 if( $HTML) { 133 print <<EOF; 134 </BODY> 135 </HTML> 136 EOF 137 } 132 printline("</BODY></HTML>"); 133 } 134 135 $output = join('',@HTTP_BODY); 136 print "Content-Length: " . length($output) . " \n"; 137 print "Content-type: text/html\n\n"; 138 print $output; 138 139 139 140 … … 161 162 my $node = $dir; 162 163 if( ! $HTML ) { 163 print "$node\n";164 printline("$node"); 164 165 } 165 166 else { … … 268 269 269 270 if( $main) { 270 print f "<TR bgcolor=$color><TD ROWSPAN=%d VALIGN=TOP><B>$if</TD>\n",(1+$subs{$if})*3,$subs{$if};271 printline("<TR bgcolor=$color><TD ROWSPAN=%d VALIGN=TOP><B>$if</TD>\n",(1+$subs{$if})*3,$subs{$if}); 271 272 $c=4; 272 273 } 273 274 else { 274 275 $c=3; 275 print "<TR bgcolor=$color>";276 printline("<TR bgcolor=$color>"); 276 277 }; 277 278 $cfg=~s/</</gi; … … 322 323 printline("<PRE>$pr</PRE>"); 323 324 } 324 else { 325 print $pr; 326 }; 327 }; 325 326 $output = join('',@HTTP_BODY); 327 print "Content-Length: " . length($output) . " \n"; 328 print "Content-type: text/html\n\n"; 329 print $output; 330 };
Note:
See TracChangeset
for help on using the changeset viewer.