Blog

Symfony 1.1 Beta 2 released - What's new?

« Back to the Blog

Categories

Archives

Creative Commons License This work is licensed under a Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 Unported License.
rss feed

We've just released a new beta version of symfony 1.1. This is the first true beta release, meaning that the API of the new features is not subject to change. It should put a stop to the addition of major functionality and internal refactoring. The next weeks will focus on testing, debugging and documenting the framework, with a target stable release in a month or two from now.

For those who didn't follow the timeline of 1.1 developments, here is a quick overview of the additions and improvements this new version offers over symfony 1.0:

  • New Command Line Utility

    • Completely rewritten from scratch (bye, pake!)
    • Now based on an Object-Oriented subframework
    • Allows for unordered named options
    • Tasks are extensible
    • Built-in help (php symfony help [taskname])
    • Reliable, easy to use and intuitive
  • New form subframework

    • Forms are now classes
    • Form Widgets represent the view layer. The subframework provides more widgets than symfony 1.0 had form helpers.
    • Native and easy handling of validation, fillin, request binding
    • Native CSRF protection
    • Native file upload validation
    • Support for nested validations and widgets
    • The Most Beautiful Form Framework You've Ever Seen In PHP - and you can even use it outside of symfony!
    • Optional (your old forms still work!)
  • New plugin manager

    • Completely rewritten from scratch
    • Supports dependencies between plugins
    • New options for more control over what you install (--install_deps, --release, --stability)
    • Support for the REST API of a PEAR channel
 
  • Improved ORM integration

    • Propel has been updated, and is now a plugin, bundled by default with symfony 1.1
    • Behaviors can now be declared directly in the schema
    • A schema can be overridden by another one
    • New configure:database task to update both the propel.ini and databases.yml dsn from the command line
    • More hooks in the code - that means more opportunities for extensions and behaviors
    • Better i18n support ($article->getTitle('fr'))
    • Improved dump/load, dealing with FK seamlessly
    • YAML schema generated from a database is now more readable
    • Support for the new Form subframework
 
  • Improved Routing

    • The routing now has a cache layer: That's a massive boost for pages with a lot of URLs to generate
    • Token separator in routes is no more limited to '/'. You can now use any characters, for instance to allow routes like /article/:title.:format
    • PJS and multiformat are on the way
    • The routing class is not a singleton anymore - that means that an application can have access to another application's routing objects
  • Improved internationalization

    • I18n now uses the same caching techniques as the view, for faster-than-ever template generation
    • A new task can find untranslated text strings in templates and add them to the dictionaries (symfony i18n:extract)
    • Another new task can find text strings without __() in templates and report them (symfony i18n:find)
    • XLIFF and gettext dictionaries can now be in multiple directories
    • The I18n class is not a singleton anymore
 
  • Improved caching

    • New caching factories, allowing to use Memcached or APC as caching storage
    • Ability to remove the cache from another application
    • The view cache manager now accepts wildcards in the remove() calls, whatever the caching factory you use
    • Partials and components in cache can now add JavaScripts and stylesheets in the main response
    • New general caching factory, for your non view-related caching needs
    • The function cache can now use any caching factory (not only sfFileCache)
 
  • Improved configuration

    • The Spyc parser was dumped, in favor of a brand new, home-made, more robust YAML parser
    • Incorrect YAML files now throw a helpful error message
    • Symfony can auto-check that it can run (check_configuration.php checks PHP version, extensions, etc.)
    • The project and application configurations are now classes, offering convenient methods to customize the project directory structure and loaders
    • An application can access another application's configuration
  • Improved Tests

    • A performance tool allows to measure the speed difference between each version of symfony - objectively
    • CSS3 selectors are now supported in the sfDomCSSSelector (:contains(), :first, etc.)
  • A gazillion little improvements that will make your life easier

    • Actions can now end by renderPartial() or renderComponent()
    • sfWebRequest now has an isMethod() method (if($request->isMethod('post')))
    • Support for many-to-many relationships in fixtures
    • Ability to execute an action on a selection of entries in the admin generator
    • More information in the Web Debug Toolbar (PHP extensions, sfUser attributes, etc.)
    • Improved error messages in Phing
 

Overall, that's not too many new features for more than a year in development. But the real beauty is in the inside. Symfony 1.1 is a major step in code extensibility. The decoupling of classes has touched every part of the framework. A large part of the job turns around a new event manager inspired by Cocoa. Also, almost every key feature of the framework is now controlled by a factory, so you can hack symfony into doing whatever you like. Not to mention that the code is more beautiful than ever - for those who can see beauty in code...

And to finish with a more general view of the code, the number of unit tests has been doubled (from 4,000 to more than 8,000). And all the bugfixes in symfony 1.0 were backported to symfony 1.1. That means that symfony is more robust than ever, and that you can use it for all your web application projects with your eyes closed.

So now you may ask: "What's the tradeoff?" You probably expect migration problems and expensive upgrade for your applications. Be reassured: Symfony 1.1 is backward compatible with symfony 1.0. That means that:

If you want to give it a try, go ahead and download symfony 1.1:

Don't forget to read the UPGRADE file - this is really important.

We will soon announce the next symfony Sprint, a day where all the community gathers to add documentation, write tests, fix bugs, and fill the gaps. And this time, the Sprint will also be an occasion to upgrade your application to symfony 1.1, with free online support from Sensio for the whole day. Keep your eyes open for upcoming news!


gravatar icon
#1 Mickael said 1 minute later

That's the best news since symfony 1.0 ;)

gravatar icon
#2 ruzz said about 11 hours later

been waiting for a stable beta.. excellent work to the whole team :)

gravatar icon
#3 Muhammad Asif ali said about 11 hours later

Great news to all symfony developers. I am eager to play with the new features but afraid to upgrade the development server which contains many symfony 1.0 projects. :-)

gravatar icon
#4 Lukasz Wojciechowski said about 11 hours later

Great news

Keep up the good work - symfony rocks

gravatar icon
#5 Jacques Philip said about 13 hours later

Nice, than you; Is the sfDoctrine plugin already fully compatible orr will this come later?

gravatar icon
#6 b00giZm said about 13 hours later

Great job guys!!!

Symfony just kicks ass.

The new features sound awesome. I can't wait to get my hands on the new version.
Are there already any detailed docs available? Maybe I'm just too blind but i couldn't figure out the differences between the 1.0 and 1.1 online documentation ;)

gravatar icon
#7 phuson said about 13 hours later

Looking forward to 1.1!

gravatar icon
#8 muxx said about 14 hours later

Francois, it's really wonderful! Only one question, what gives with symfony performence time?

gravatar icon
#9 jarod51 said about 14 hours later

François for president !!!

gravatar icon
#10 Jerome said about 14 hours later

Sounds great...

but it seems admin generator is still 1.0-based. Is it planned to be rewritten usgin 1.1 version ?

If not, it will be hard to maintain an application written 2 different standards...

Hope Symfony team will answer this.

gravatar icon
#11 Jerome said about 14 hours later

Sounds great...

but it seems admin generator is still 1.0-based. Is it planned to be rewritten usgin 1.1 version ?

If not, it will be hard to maintain an application written 2 different standards...

Hope Symfony team will answer this.

gravatar icon
#12 Jordi said about 15 hours later

I am a happy man ...

gravatar icon
#13 gasper_k said about 15 hours later

Congratulations! :)

gravatar icon
#14 z01d said about 16 hours later

Thank you!

gravatar icon
#15 Vitaille said about 16 hours later

Great Job...!!

So many feature and changes...

Why didn't you call it Symfony 2.0 ???

gravatar icon
#16 Hugo said about 18 hours later

Good job guys ;)

I hope I could use this new Symfony version for my new projects :D

PHP and Symfony rocks !

gravatar icon
#17 Jeff said about 18 hours later

wow it's amazing...

Great news for all symfony developers.. Symfony rocks !

gravatar icon
#18 Celso said about 19 hours later

excellent!!

gravatar icon
#19 hartym said about 20 hours later

great i hope this will be stable soon ^^

gravatar icon
#20 Joan Piedra said 1 day later

These are great news, thanks for all the devoted work on this awesome framework.

A quick question, is it possible to use dashes, underlines, or commas in this new routing system?

gravatar icon
#21 Dejan Spasic said 1 day later

Just breathtaking.

Thank you!

gravatar icon
#22 Skyblaze said 1 day later

Is it updated also the crud code generation? I mean the 1.0 version creates action code and template code using object form helpers that in 1.1 are deprecated in favor to the new form system

gravatar icon
#23 Marek said 1 day later

Is pear install working for anyone?

$ pear remote-list -c symfony
Channel symfony Available packages:
===================================
Package Version
pake 1.1.4
sfEzpdo -n/a-
symfony 1.0.12

$ pear install symfony/symfony
Ignoring installed package symfony/symfony
Nothing to install

(after channel-update)

gravatar icon
#24 Laurynas Malisauskas said 1 day later

i hope the upcoming sprint will concentrate on documentation the most, in order to make possible for not so experienced users to upgrade from 1.0.x to 1.1

gravatar icon
#25 Christopher Brunsdon said 1 day later

Thanks guys. Just did my PEAR upgrade and it has come in. :-)

gravatar icon
#26 halfer said 1 day later

Lovely, thanks chaps. I shall use the beta for a subsection of my new project, and I dare say if it all goes to plan, the rest will be converted to 1.1 too!

gravatar icon
#27 Sergey said 4 days later

Some problem for my - downloaded sandbox, created schema.yml, do propel-build-all, then propel-insert-sql and propel-generate-crud. Everything created and available. But then i try to create record from crud interface, error message appeared - csrf token: Required.

what can i do?

gravatar icon
#28 Gnagno said 4 days later

congratulations for the great work!!!

Is there any page documenting how to use the new features?

gravatar icon
#29 Dharmavirsinh Jhala said 4 days later

Bingo..!
I have been waiting for this release since long. Many congratulations to Symfony Team.
http://blogs.digitss.com/

gravatar icon
#30 mad said 4 days later

any new things in the admin generator?

gravatar icon
#31 Christian Schaefer said 5 days later

Thanks so much guys! I've been working with 1.1-DEV for a good three months now following closely how it evolves and I love it! An extraordinary minor release this is! Brilliant work! Cheers

gravatar icon
#32 JEANTET Valere said 6 days later

good job !

gravatar icon
#33 vinilios said 7 days later

Looks amazing, keep it up ppl !!!

gravatar icon
#34 john said 12 days later

Pear doesn't appear to have the beta version:

mini:~ john$ pear remote-list -c symfony
Channel symfony Available packages:
===================================
Package Version
pake 1.1.4
sfEzpdo -n/a-
symfony 1.0.13
mini:~

mini:~ john$ sudo pear install symfony/symfony-beta
downloading symfony-1.0.13.tgz ...
Starting to download symfony-1.0.13.tgz (1,914,365 bytes)
....
install ok: channel://pear.symfony-project.com/symfony-1.0.13
mini:~ john$ sudo pear upgrade symfony/symfony-beta
Nothing to upgrade
mini:~

gravatar icon
#35 john said 12 days later

Ah, Fabien addresses the symfony-beta problem here in comment #2: http://www.symfony-project.org/blog/2008/04/01/symfony-1-0-13-is-out

mini:~ john$ sudo pear install symfony/symfony-1.1.0beta2
downloading symfony-1.1.0beta2.tgz ...
Starting to download symfony-1.1.0beta2.tgz (2,057,855 bytes)
....
install ok: channel://pear.symfony-project.com/symfony-1.1.0beta2
mini:~ john$ symfony --version
symfony version 1.1.0-BETA2 (/opt/local/lib/php/symfony)
mini:~

gravatar icon
#36 Justin said 28 days later

FYI, if it helps someone else:

I installed 1.0 first. When I tried to install the 1.1 beta, it did this:

$ pear install symfony/symfony-beta
Ignoring installed package symfony/symfony
Nothing to install

So I ran the uninstall of the non-beta, and then that worked. So if you get that error, and want to have 1.1 instead of 1.0, try this:

pear uninstall symfony/symfony

then try to install the beta as per instrucitons.

gravatar icon
#37 Justin said 28 days later

FYI, if it helps someone else:

I installed 1.0 first. When I tried to install the 1.1 beta, it did this:

$ pear install symfony/symfony-beta
Ignoring installed package symfony/symfony
Nothing to install

So I ran the uninstall of the non-beta, and then that worked. So if you get that error, and want to have 1.1 instead of 1.0, try this:

pear uninstall symfony/symfony

then try to install the beta as per instructions.

gravatar icon
#38 vv said about 1 month later

How do you upgrade it?
I'm running 1.1beta4

c:\php>pear upgrade symfony/symfony-beta
Nothing to upgrade