HylaFAX The world's most advanced open source fax server

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [hylafax-users] Template: Could I include Php script ?



Quoting borgo2000@xxxxxxxx:

Could I execute a php script from html email template files?
(/var/spool/hylafax/etc/templates/)

I have used the #INCLUDE command to add a text file into any email messages
sent from hylafax and it works very well..
Now, I would like to use a PHP script inside the template syntax like this:

#INCLUDE "php /tmp/helloworld.php"

or

#INCLUDE "/tmp/start_php_helloworld.sh"

Is it possible or does it work only for plain text ?????

#INCLUDE only includes the text as is. What you can do, is create a hook.sh script file (in the same directory than the templates files) that will call your php script and save it's output in an environment variable. This variable can then be used in your templates where you want the php output to appear.



-- Patrice Fournier iFAX Solutions, Inc. www.ifax.com


____________________ HylaFAX(tm) Users Mailing List _______________________ To subscribe/unsubscribe, click http://lists.hylafax.org/cgi-bin/lsg2.cgi On UNIX: mail -s unsubscribe hylafax-users-request@xxxxxxxxxxx < /dev/null *To learn about commercial HylaFAX(tm) support, mail sales@xxxxxxxxx*




Project hosted by iFAX Solutions