Posts Tagged ‘Symfony’
How to optimize frontend in Symfony (CSS & JavaScript)
What ?
If you’re looking forward to optimize the frontend in your Symfony project or to introduce different CSS or JavaScript versions to each language in your application there’s a nice plugin that will help you with that. It’s called sfMinifyTSPlugin and it integrates Google’s minify library so you know it’s good stuff
.
Why ?
What makes it stand out from the rest of Symfony minify plugins is the fact that you don’t need to change anything in your .htaccess file or any other server stuff, just an out-of-the-box cool plugin.
The other nice thing about it is that you can implement it either as a filter or with a helper.
The fun part is also that the authors implemented some symfony tasks to help you clear-cache and fix permissions.
The cache files names are generated with a date so you’ve got all the usefull info about it and speeds up your web application just like that.
So don’t hesitate to experiment with this cool plugin in your future Symfony applications.
Why Symfony Is The Best Framework To Start ?

I thought I might put in a few good words for Symfony to all of you wandering which PHP framework to choose. Because there’s a whole bunch out there some of them worth mentioning are f.e. CakePHP, Zend and Symfony.
Why Symfony ?
The tutorial
First of all, the main reason that appealed to me when I started was that there is a whole 24 day-by-day tutorial which will teach you all you need to know about Symfony to get you started. Of course you won’t get a good grip of the framework after finishing the tutorial, but it should encourage the desired way of thinking in you. The Jobeet (set of 24 tutorials) covers everything you would want to know to build a basic website, from setting up the project, through forms, to f.e. having fun with AJAX
.
The documentation
This is the first place to go whenever you feel you have doubts about writing some snippet of code. This is practically the holy book of Symfony where all the laws are writtend down. Symfony’s documentation is written in a not complicated language and when you’re looking for something in particular it’s made in a way that you won’t spend hours searching the desired topic. So basically this and the jobeet tutorial are the pros which make Symfony a framework reaching out a hand to the developers.
Plugins
Writing about plugins is basically the point where the Symfony community should get the needed applause. Whenever you’re searching for a functionality or thinking on a way to design one, go here first. There are a lot of useful ones there f.e. a plugin for Twitter, Facebook or a plugin for user authorization. And most important they are lively developed.
ORM
I’m using at the moment Propel as my primary ORM but the default choice in near future will be Doctrine. Anyway, forget about writing long and pesky SQL statements. You’ll just love the object methods that handle all the stuff for you. All you need to the is focus on your applications goal and Symfony will handle your database in neat objects, ain’t it fun
?
The tasks
This is where the fun part is as well. Building symfony and integrating it with your database is just a few words typed in the command line away. Just type ./symfony in your project’s directory and you’ll get the list of all the tasks that’ll help you on your way to finish your application. The more confident you’ll get with symfony, the more fond you’ll find yourself of those sneaky little bastards that make a developers day easier.
Because It is fun to learn !
Yeah, that’s wright. And you should check it as well. Take it for a spin, spend time with it and you’ll see that after each day you’ll get more anxious to learn new stuff and after a few weeks you’ll wonder why didn’t you find it earlier
. Of course it is hard to mention all the great stuff about Symfony, but i think I’ve drawn the picture for you, why it is the best one to start with. Have fun and good luck
!
Symfony tutorial: rich date pickers with sfFormExtraPlugin

Step 1:
We will be working with sfFormExtraPlugin and sfWidgetFormJQueryDate, so first of all you need to install the sfFromExtraPlugin itself:
./symfony plugin:install sfFormExtraPlugin

