Hi,

I tried it out with this:

<FilesMatch ".*.epl$">
  SetHandler  perl-script
  PerlHandler Embperl
  Options     ExecCGI

#  Order allow,deny
#  Deny From all
</FilesMatch>

AddType application/x-httpd-php .php

<FilesMatch .epl>
  SetHandler  perl-script
  PerlHandler Embperl
  Options     ExecCGI
</FilesMatch>

AddType application/x-httpd-php .php


A test.epl:

<html>
<head></head>
<body>
 [- $test="Hallo" -][+ $test +]

[$ syntax EmbperlBlocks $]

[-
$r = shift ;
Execute ({subreq => '/test.php'})
-]

</body>
</html>

a test.php:

<html>
<head></head>
<body>
<h1>Test PHP</h1>
<?php echo "Test" ?>
</body>
</html>


But it ended in:

Internal Server Error
The server encountered an internal error or misconfiguration and was
unable to complete your request.
Please contact the server administrator, [EMAIL PROTECTED] and inform
them of the time the error occurred, and anything you might have done
that may have caused the error.


[76195]ERR: 675407878: test.php(1): Error (no description) 675407878
(status=200) /test.php  

Embperl/2.0b9_dev-3 Apache/2.0.43 (Unix) mod_perl/1.99_08-dev
Perl/v5.6.1 PHP/4.2.3 mod_ssl/2.0.43 OpenSSL/0.9.6g [Thu Jan 2 05:13:39
2003]


By the way...

Do you think a

<FilesMatch .php>
  SetHandler perl-script
  PerlHandler Embperl::Object
  Options ExecCGI
</FilesMatch>

could be set up to work

J�rg


P.S.
Please save me some lookup time... ;-) where to place
optDisableFormData?

-----------------------------

wolf-systems IT-Services Inh. J�rg K�temeier
http://www.wolf-systems.net


-----Urspr�ngliche Nachricht-----
Von: Gerald Richter [mailto:[EMAIL PROTECTED]] 
Gesendet: Mittwoch, 1. Januar 2003 21:05
An: J�rg K�temeier; [EMAIL PROTECTED]
Betreff: Re: AddOutputFilter EMBPERL ???


>How do I add Embperl as an Output Filter?

The only way it works for now is calling your PHP page from Embperl,
like

[- Execute ({subreq => '/uri/path/to/foo.php'}) -]

So you can use Embperl::Object:

Embperl_Object_Base base.epl
Embperl_Appname phpfilter

and in base.epl you write

[-
$r = shift ;
Execute ({subreq => $r -> param -> unparsed_uri})
-]

Additonaly you should tell Embperl not to read in the POSTed form data,
other wise PHP will not see them by setting

optDisableFormData


Gerald





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to