You have got a couple of options, but none of them are good!
- you can get perl to execute a PHP script using the standalone CGI version of PHP and do something with the results that it generates (this will only allow you to parse and alter the output of the PHP program, it won't actually let you call a PHP function).
- You can use Apache2 and mod_perl2 which allow you to write a mod_perl Filter that can filter the output of mod_php (again, it is only working on the output generated by PHP)
- A quick search on CPAN for PHP found PHP::Include. This module claims to be able to parse very simple PHP, and convert it to perl code. So depending on how complex your PHP is, it might be an option.
- Convince someone to write Inline::PHP... Good luck with that one, since I don't think there would be much demand for that.
Without knowing how extensive the code is that you would like to run, my recommendation would be to rewrite your PHP in perl. PHP doesn't do anything that perl can't do...
- Cees | [reply] |
| [reply] |