Purchasing a 3rd party code encoder/decoder is not an option for me since I simply deliver the desired solution. In order to deliver a closed source application, would a middleware php app (non-extension) working as an encoder/decoder work?
The idea is to have the app encode the code before delivery and then deploy it for decoding for interpretation such that each page request passes through this script using maybe .htaccess with mod_rewrite directives. Since most production servers come with full fledged apache and php installations this could be deployed anywhere.

The point however is whether such a system would work, no doubt it would lead to some performance loss, but is it possible to have such a system deployed ?