<?xml version="1.0"?>
<!-- name="generator" content="blosxom/2.0" -->
<!DOCTYPE rss PUBLIC "-//Netscape Communications//DTD RSS 0.91//EN" "http://my.netscape.com/publish/formats/rss-0.91.dtd">

<rss version="0.91">
  <channel>
    <title>e dot dot dot 07 01 2006</title>
    <link>http://www.jamesraposa.com/index</link>
    <description>e dot dot dot - a mostly about the Internet weblog by James Raposa</description>
    <language>en</language>

  <item>
    <title>Amazing Perl output capturing `sniplet`</title>
    <link>http://www.jamesraposa.com/index/2006/01/07#perl_stdout_capture</link>
    <description>Here's a terrific little chunk of code I found while searching for a way to capture some output from a Perl script, the output of which was being used in a Server-Side-Include.&lt;br /&gt;&lt;br /&gt;I wanted the ability to use the same script, capture the output into a variable,  then &quot;escape&quot; the output for use as a javascript feed.&lt;br /&gt;&lt;br /&gt;It works like a charm.  All output going to STDOUT is captured into a variable  without requiring any modification to your original subroutine.&lt;br /&gt;&lt;br /&gt;You're then able to do some work on it before PRINTing it to the restored STDOUT.&lt;br /&gt;Try it for yourself.&lt;br /&gt;&lt;!--dl_filename:stdout_redir.pl--&gt;</description>
  </item>
  </channel>
</rss>