Hi,
Is it possible to use php functions in hescript?
I need base64_encode for now, but don’t know how to use it in hescript
Thank you
Hi,
Is it possible to use php functions in hescript?
I need base64_encode for now, but don’t know how to use it in hescript
Thank you
No, it’s not possible. You can run HEScript from PHP but not the contrary.
Maybe you could think about add posibility to use internal php.exe because it is just compiled. It could be simple one line commands, but it helps us a lot, because no one is hescript experts
php -r ‘echo base64_encode(“something”);’
Sure, we’ll check whether this can be done this way.
Please check if in hescript could call script inside compiled application and if return from this script can be assign to hescript variable. It could be powerfull.
Pseudocode
SomeVariable := PHP(‘tools.php?var=’ + getglobalvar(‘something’);
Did you think about it if it is possible?
We added the ability to run PHP code in HEScript thanks to the new ExecutePHPScript function.
Example code:
procedure TestRunScript;
var
SRes: String;
begin
SRes := ExecutePHPScript("<?php echo 'TEST'; ?>");
ShowMessage(SRes);
end;
great, I can not wait for the new version
Can we run php script and output assing to SRes? and how to do is?
procedure TestRunScript;
var
SRes: String;
begin
SRes := ExecutePHPScript("<?php include("test.php") ?>");
ShowMessage(SRes);
end;
It will normally work provided that test.php
lies in the application’s root folder (the source folder).
There was a HTML cleanup problem in the post-processing… It’s fixed in the online version, thanks!
https://www.exeoutput.com/help/scriptreference