my $scalar = "some pod text"; tie *STDIN, 'IO::Scalar', \$scalar; pod2html; untie *STDIN; # reads from 'real' STDIN, not from $scalar