On Mon, Apr 9, 2012 at 6:54 PM, Kris Craig <kris.cr...@gmail.com> wrote:
> Again though, the problem here is that you're relying on the including
> script to determine whether a PHP script is pure or not; i.e. this approach
> leaves no way for that to be determined in the file itself.  For example, I
> can see perfectly valid instances where it would be ideal to execute one of
> these pure scripts as a direct call to the webserver-- AJAX being a prime
> example.  I.e. cases where you want backend PHP processing to take place but
> it has to be accessed via the browser (most likely "hidden" as an AJAX query
> though).

As others have pointed out, the proposal could be amended to include
options for the CGI, FPM, etc. SAPIs so that Apache and other servers
could be configured to recognize a specific file extension as starting
out in code mode, if desired. The CLI SAPI could have an option too.
I'm not opposed, I just don't feel as strong a need for it because I
normally write framework code that uses autoloaded classes, not
standalone directly accessed scripts. This would address your concern
without hardcoding file extensions into PHP itself.

The rest of your comments are pretty close to alterations I plan to
make to the RFC.

-- 
Tom Boutell
P'unk Avenue
215 755 1330
punkave.com
window.punkave.com

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to