4 ms·
Symfony is somehow able to make PHP programming seem very elegant... I never understood all the hate against PHP while tucked safely inside the framework. The m
by j_m_b 13y ago
Symfony is somehow able to make PHP programming seem very elegant... I never understood all the hate against PHP while tucked safely inside the framework. The main drawback to Symfony is the endless amount of configuration that is done through YAML files and pure PHP. The configuration files are spread throughout the project dir and can be a bit confusing. To paraphrase a famous quote: "I would rather have one configuration file that configures 100 things than 10 configuration files that configure 10 things". After migrating to Symfony 2.0, one day I wanted to make a simple column change in my database and it took me TWO freakin' days to figure out how to properly configure the ORM! I've since abandoned PHP/Symfony/Javascript for Clojure/Clojurescript and I haven't looked back!
- jtreminio 13y agoDid you bother reading the extensive documentation? You can quickly figure out how to do this within 10 minutes for your first time.
- sheraz 13y agoI completely feel your pain with regard to Symfony. That, and the required verbosity in coding left me feeling lost in a language I thought I knew. Even after a couple projects I still didn't "get it." Most of my time was spent in the docs and stack overflow trying to learn the "symfony way" of doing things rather than just getting it done. - Too much nesting, both in file layout and yaml configurations - Too many different ways to do things (YAML, PHP, .ini, file annotations) - Too verbose when coding (namespaces, long class and method names) - And don't get me started with Twig I took those hard knocks and tried to write my own mini-framework, which only taught me why you don't write frameworks. It is really hard to do well. Then I found laravel [1] and have been impressed. It is more opinionated than Symfony and feels more cormfortable to develop on. Less configuration, less verbosity. I combed through the docs and had a project up and running in two days. But here is the real nugget, kids. Using a framework on a long-term project is like marriage. It takes commitment. You will be in it for a while, so you had better make sure you can live with it. You have to invest your time and effort into it to understand it as much as possible -- warts and all.
- porker 13y agoWhat kind of apps or websites were you developing sheraz? I'd like something less complex than Symfony, but Laravel doesn't seem as feature-complete for complex applications. Form definitions seem much more lightweight (I build 9+ page loan application forms, multi-page legal forms with repeating regions, add-remove rows etc), APIs and REST interfaces - the works. I want to change framework, but I get the impression most of the others have a smaller-project sweet spot. [And yes, I know large stuff can be built with the others, like it can with Drupal. But does the framework make it as/more easy than Symfony, that's the question?] A free rant :): I hate the Doctrine ORM for it's hideously bad documentation (either missing information or written by core devs for core devs -- I can't contribute to improving it as I don't understand it well enough!) yet I appreciate a 'real' ORM vs an ActiveRecord+QueryBuilder system. Gah.
- MAGZine 13y agoIs Silex too heavy or too light for your usage?
- jrgnsd 13y agoSilex is definitely a good lightweight alternative. For enterprise work Symfony 2 is a better choice, but if you need to throw things together (but need to keep the option of adding more features without writing them yourself) you can easily integrate a bunch of the Symfony 2 components into Silex.
- wldlyinaccurate 13y agoI wouldn't call Silex "lightweight". Slim, however, is very lightweight and a pleasure to use: http://slimframework.com/ http://slimframework.com/
- porker 13y agoI think too light, but I don't think I've ever got the concept straight in my head. I thought it was a mapper from a URL parameter to a function - the first two code examples in http://web.archive.org/web/20130402141837/http://edorian.posterous.com/a-silex-love-story-embedded-php http://web.archive.org/web/20130402141837/http://edorian.pos... are what I understood it to be. TL;DR: I think Silex has changed a lot since I looked at it. I can't give you a good answer.