Jump to content
PavelX

TIdHTTPServer -> run PHP code Cross-Patform including Android 10

Recommended Posts

Hi,

 

Just wondered does any of you guys,  know / has any experience  on  how to allow TIdHTTPServer run a PHP script file (cross platform LINUX/MACOS/WINDOWS/ANDROID)

*Note - Starting with android 10 exec is forbidden.

https://developer.android.com/about/versions/10/behavior-changes-10  - Removed execute permission for app home directory

 

A starting point with some code examples will be greatly appreciated.

 

Thank you in advance,

Pavel

 

Share this post


Link to post
3 hours ago, Fr0sT.Brutal said:

Delphi-powered HTTP server running on Android

Yes.

Quote

and executing PHP scripts?

On Android, maybe, maybe not.  ISAPI is IIS-specific, and support for ISAPI has been dropped from PHP.  So, if you can execute the PHP CGI executable AND redirect its STDIN/STDOUT on Android, or if you can find a FastCGI processor that works on Android, or if you can compile the PHP core library (or 3rd party implementation) directly into your app, then you might have a chance.

Edited by Remy Lebeau

Share this post


Link to post

After a long research I have abandoned the idea. It looks very difficult for Android.

 

I have found one delphi implementation for FastCGI

https://github.com/EvgeniyKorepov/FastCGIClient/blob/master/UnitFastCGI.pas

But I cannot find php (php-fpm) binaries for all platforms especially for android

And also I have no Idea if will work. 

How can I start FastCGI daemon if android 10 has removed the execute permission for app home directory?

 

Thank you very much,

Pavel

Share this post


Link to post

Just wondering: what's the sane usage scenario this Frankenstein's monster has?

Edited by Fr0sT.Brutal

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×