I did it but it's not working because enviroment varible which I have
defined seem to be empty (not global). I have created two files in
/var/spool/hylafax/etc/templates/custom:
First is hook.sh
#!/bin/bash
TEMPLATE_VAR_1=$(php /var/spool/hylafax/etc/templates/custom/hook.php
$SESSION_LOG)
export TEMPLATE_VAR_1
The second is hook.php
<?php
$txt = htmlspecialchars($argv[1], ENT_QUOTES);
echo $txt . "n";
?>
Here is my template file:
.....missing code.....
Test: $TEMPLATE_VAR_1
The problem is that $TEMPLATE_VAR_1 is always empty. I think that the
enviroment variable set in the bash script have local scope.
Any ideas ?