On 7 Oct 1999, Randal L. Schwartz wrote:
"Stas" == Stas Bekman [EMAIL PROTECTED] writes:
Stas yes, there are... you get a code like:
Stas sub handler{
Stas print "hi\n";
Stas =pod
Stas =head1 Hi
Stas =cut
Stas }
Stas which is syntaxically incorrect, pod directives
On Fri, 8 Oct 1999, Matt Sergeant wrote:
On Fri, 08 Oct 1999, Stas Bekman wrote:
On 7 Oct 1999, Randal L. Schwartz wrote:
"Stas" == Stas Bekman [EMAIL PROTECTED] writes:
Stas yes, there are... you get a code like:
Stas sub handler{
Stas print "hi\n";
Stas =pod
The guide points out that __DATA__ and __END__ tokens are not allowed in Registry
scripts. However, the error generated into the logfile in this case complains
"Missing right bracket", and the line given is the last script line before the
token. Oddly, if one *adds* a (syntactically incorrect)
On Thu, Oct 07, 1999 at 03:59:37PM +0200, Stas Bekman wrote:
That's almost correct, what it does is taken a script sitting at
URI /perl/test.pl:
print "Content-type: text/plain\n\n"
print "mod_perl rules!\n"
perl actually sees it as:
package Apache::ROOT::perl::test_2epl;
So if you script included __END__ or __DATA__ token like:
print "Content-type: text/plain\n\n"
print "mod_perl rules!\n"
__END__
some junk here
perl actually sees it as:
package Apache::ROOT::perl::test_2epl;
use Apache qw(exit);
sub handler {
"Andrei A. Voropaev" [EMAIL PROTECTED] writes:
Would it be possible to remove everything after __END__ before
wrapping it into a function?
That requires a full-blown perl parser, to decide if __END__ is really
__END__.
print "Content-type: text/plain\n\n"
print EOT;
# Example perl code
#
#
make __DATA__ available to which subroutine??
only way I can think to do that effectively is: read the data, write it to a
temporary file, watching our for any security concerns, and replace the
standard DATA file handle with on that is opened to the temporary file that
was written.
cliff