News for hackers. Stuff that matters.
Re:PHP 8: Before and After by mtberatwork on Friday October 23, 2020 @08:15AM (#24868628)
Isn't this what PHP still is? Can't you just drop index.php into a directory?
Re:PHP 8: Before and After by mgkimsal on Friday October 23, 2020 @08:30AM (#24868746)
Was going to ask the same thing.

There's not much in PHP 5/7/8 which precludes just doing some raw db queries and including some templates.

The biggest 'drawback' might be that there's not one name-branch 'framework' which takes this approach (indeed, it's the opposite of 'framework' thinking). But if there was some project that documented/demonstrated 'best practices' for 'non-framework' projects, it might help reduce the "I need a framework because raw PHP is so messy" objections.

Re:PHP 8: Before and After by Macuyiko on Saturday October 24, 2020 @06:26PM (#24882392)
> The biggest 'drawback' might be that there's not one name-branch 'framework' which takes this approach

Exactly! That comes close to the point I wanted to make

Re:PHP 8: Before and After by Macuyiko on Saturday October 24, 2020 @06:25PM (#24882386)
It is, but also note my other points:

1 - security-safe and type-safe from the beginning 2 - none of the additional programming paradigms. PHP wants to be everything in one language. I know you can still use PHP "basics" like that, but it's not going to be easy to find tutorials etc. showing that

The main point I wanted to make was not about the index.php file. In other words, I'd like a PHP3, but a clean, safe, very well-designed one.