Re:PH7 – An Embedded Implementation of PHP (C Library)
by symisc_devel on Wednesday February 19, 2014 @12:03PM
(#7264582)
Yes, most of the built-in functions (over 470) are foreign C/C++ functions installed exactly using the same interface: ph7_create_function();
Re:PH7 – An Embedded Implementation of PHP (C Library)
by stevekemp on Wednesday February 19, 2014 @12:48PM
(#7264890)
Yeah that was pretty nice to see.
My first thought on seeing this project was wondering how hard it would be to hook up to nginx, or similar. I don't really "do" PHP, so I'd probably not attempt it myself, but I get the feeling from having written nginx modules in the past that this doesn't look too hard - the PH7 API seems decent enough.
Re:PH7 – An Embedded Implementation of PHP (C Library)
by frik on Wednesday February 19, 2014 @02:13PM
(#7265509)
Interesting, please write a blog post if you investigate this. It could be like OpenResty (Lua + Nginx): http://openresty.org
I am using HHVM (Facebook's HipHop PHP w/JIT) with Nginx. that works great... but it requires a 64-bit server. So for smaller servers or embedded systems Ph7 sounds interesting.
Does anybody know if it's easy to make new functions available to PHP that would call into the C main program?
It says "Built with more 470 function" how does that compare with standard PHP? If I take some PHP I've previously written or a library, is it going to run with minor modifications? Or is this a subset of PHP?