4 ms·
That is such a well articulated observation, it resonates strongly with my own experience. I grew up on PHP, it was the first thing beyond BASIC I ever wrote,
by dusted 4y ago
That is such a well articulated observation, it resonates strongly with my own experience.
I grew up on PHP, it was the first thing beyond BASIC I ever wrote, and I wrote a lot and enjoyed it so much. It really was this magic thing, that you just modified whatever file you needed to modify, throw it on the server, and hit f5 to see your changes reflected.. No processes to restart, no state to be lost, you jammed, and it was a very gentle way to learn.
- hlandau 4y agoAuthor here. I have very, very similar childhood memories of PHP. It really was a magic thing to mess around with - I think a lot of people had this experience. I suspect back then a lot of people learnt webdev this way. Sadly I suspect it's less common now. Back then the "LAMP" stack was common enough that there were turnkey packages for Windows that setup "LAMP" for you. Was one called Wampp, or something? I forget. At first I liked using a particular proprietary web server for Windows called 'Sambar Server' which made learning easy due to its PHP support and web GUI config editor. Later setting up Apache, PHP and MySQL on a new Windows install became a common habit for me, once I learnt how to do it. I would make PHP websites and host them locally, then show them to people by giving them the IP (and this was over dialup!)
- markdown 4y agoWAMP for Windows, MAMP for Mac.
- oldsecondhand 4y agoThere's also XAMPP
- deleted 4y ago[deleted]
- commandlinefan 4y ago> similar childhood memories of PHP. I really wish y'all would stop making me feel old by reminding me that there are now grown-ups who were children when PHP existed.
- Random_Person 4y agoThis pretty much describes my day job and I love it. Is our codebase a hot mess? Yeah, we have lots of debt from previous devs, but we're working on it!
- commandlinefan 4y agoI remember working with PHP and initially being impressed by its simplicity but quickly being overwhelmed by its restrictiveness. I could tell that there was some sort of higher level of abstraction that could make it more maintainable long term - I even came up with some simplifications of my own that made routine maintenance easier (for me). The problem I've seen is that everybody else had the same thought and came up with their own "simplifications" that they did a much better job of marketing than they did of marketing and now we're stuck using their "frameworks" because to do otherwise invites accusations of "wasting time reinventing the wheel".
- tored 4y agoWhat is nice is that it easier than ever to write minimal framework, somethings I think you should accept, like using composer and some of the common libraries, however bootstrapping is something I prefer to do myself. I'm having a renaissance with minimal PHP framework. My current iteration looks something like this, and it is only a few functions to do it (I do use a router library, no point of reinventing that) return #[Route(method: 'GET', route: '/projects/{project_uid}/edit')] #[Template(path: __DIR__ . '/template/template.php)] function (Request $request, ProjectRepository $projectRepository) { $projectUid = ProjectUid::of($request->vars['project_uid'] ?? ''); if ($projectUid === null) { return [__DIR__ . '/../errorView.php', [400, 'Missing project_uid']]; } $project = $projectRepository->getProjectByProjectUid($projectUid); if ($project === null) { return __DIR__ . '/../notFoundView.php'; } ?> <div class="container"> <h1><?= escape($project->title) ?></h1> </div> <?php }; Attributes is huge imporovemt to writing a small framework, attributes can not only be used for help setting up routing, HTML templating but other things as middlewares, output buffering, dependency injection. I think we should resist the takeover of large frameworks, and the thing is if you are architecting your application properly, it should be framework independent anyway. Unfortunately many ideas in large frameworks makes it harder or at least invites the developer to make the framework takeover the application.