Re: [RFC] New .phpp File Type for Pure-Code PHP Scripts
| From: | David Muir | Date: | Thu, 12 Apr 2012 23:46:11 +0000 |
| Subject: | Re: [RFC] New .phpp File Type for Pure-Code PHP Scripts | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-59811@lists.php.net to get a copy of this message | ||
On 13/04/12 09:38, Yasuo Ohgaki wrote:
> Hi,
>
> 2012/4/13 Kris Craig <kris.craig@gmail.com>:
>> Per recent discussions, I have drafted an RFC for this. This proposal
>> offers what I believe to be a more sane and realistic approach to
>> addressing the question of incorporating a new breed of tag-less PHP
>> scripts.
>>
>> https://wiki.php.net/rfc/phpp
> This may work for LFI issue for new codes.
> Few questions.
>
> CLI may use .phpp as PHP script always. (i.e. execute w/o <?php or else)
> It's like DOS, though.
>
> How do you enforce .phpp as script only for Web?
> Is it a rule for configuration? or .phpp just never supposed to locate
> under docroot?
> It relates previous question. How about bootstrap script for frameworks?
>
>> A regular .php script cannot be included from a .phpp script. An E_WARNING will be thrown
>> for include and an E_RECOVERABLE_ERROR will be thrown for require; in both instances, the included
>> file will be ignored.
> Some people may try to make .phpp handled by web.
> I cannot tell if this setting is going to be popular, but if it
> does, isn't it the end of embedded PHP?
> It might be good if PHP is more tolerant for this usage.
>
> Regards,
>
> --
> Yasuo Ohgaki
> yohgaki@ohgaki.net
>
That's a huge WTF that a templating library can't be written as .phpp,
because it then won't be able to load a template.
David