3 ms·
It still baffles me that whenever an article like this comes up, people still justify choosing PHP because of its ease of setup compared to other languages. Ser
by mekoka 13y ago
It still baffles me that whenever an article like this comes up, people still justify choosing PHP because of its ease of setup compared to other languages. Seriously? What are you going to tell me next, that you chose Ruby because the "Hello World" tutorial was 15 minutes shorter, than the Java one? Come on now.
Yes, the fact that PHP is easy to setup may explain its popularity, it doesn't however justify choosing it, considering that you may spend 2 or 3 days setting up a tool that you'll end up using day in and day out for the next couple of years, to do much more difficult things than just greeting the world on a blank web page.
- Tloewald 13y agoThere's a big difference between easy to set up (requires no setup) and a bit harder to setup (requires a different and more expensive ISP and then a bunch of extra effort). The reason I picked PHP for a project years ago wasn't because it was easier for me to set up, but because it would be easier for users of my code to set up. If you're writing code to work on your servers that's a different thing altogether. Similarly I picked PHP for a later project simply because it was available and configured, whereas anything else would have had to go through approval and tech support. For my personal stuff I use a shared server (dreamhost) which is pretty typical for low-end providers. PHP isn't merely easier, it's possible. Now my professional stuff goes on dedicated servers, so that's great. But the problem with them is that when I want to tinker, I want something really simple and foolproof to work with. If I come back after not looking at a side project for several years, I'd like to not have to spend days figuring out the runtime setup. We are getting close to a better world. I see a lot of pretty cheap/free and convenient options for hosting node and rails projects, but usually database access is yet another stumbling block.
- enimodas 13y agoLots of hate for php in this thread, but this has me thinking: does anyone know a better solution to solve my problem? I have to build a CRUD-like webapp for some database, and with a bunch of authentication and authorization. Lots of forms and reports, think MS access. I was planning to use symfony2 and a generator bundle for this, as symfony2 has those things build in and the generator will write a lot of the code i need. I'm also pretty time constrained (2 weeks), but I'm still curious what other options there are out there or how other people would solve this.
- Iftheshoefits 13y agoThat depends on your skills. The time constraint you provided leaves little room for other solutions you aren't already familiar with. That said, for your use case (since you're thinking of symfony2, it's clear that performance isn't an issue/concern: http://www.techempower.com/benchmarks/#section=data-r8&hw=i7&test=db http://www.techempower.com/benchmarks/#section=data-r8&hw=i7...) I think Django is almost certainly a superior alternative. It comes with a built-in authentication and group/role-based authorization system, a built-in 'admin' system that can be used to serve up basic CRUD forms for your models with minimal effort, and the ability to code custom 'reports' as add-ins to the built-in admin system with only minimal additional effort. If your models aren't terribly complex you could have a test-ready basic CRUD app matching your description in less than 30 minutes, 90% or more of the code for which will have been generated (or come pre-packaged) for you.