Btw, seems that the "Zend Engine", which is PHP's core implementation
in C, has a PHP equivalent to Tcl_Eval,
call_user_function_ex().
So given that PHP already runs adequately in AOLserver, adding
bi-directional Tcl/PHP support should be entirely feasible. The
AOLserver support currently included with PHP 5.0.0 beta3 definitely
doesn't have any such support though, I just looked.
I imagine the first step is to stick in the basic support for Tcl
calling PHP and PHP calling Tcl, and start coding up friendly PHP APIs
to Tcl functionality and vice-versa. Then probably later once the
basics are working, change as many AOLserver/PHP API functions as
feasible to call the underlying AOLserver C code directly (just like
the Tcl API does), for performance. (Especially the database API!)