Put the Symfony2 web profiler toolbar on top

Publié le 13/09/2012
Par Damien
128 mots

Précédemment sur le blog : Améliorer les exceptions de Symfony2

A quick and easy Symfony2 protip© today!

As you may have noticed, the Symfony2 web profiler toolbar is at the bottom of your website by default, instead of the top position used for years in symfony 1.

This is not a bad choice but depending on your project design, it may be needed to move it on top,
like the good old days :).

And guess what! There is an option for that!

This is not much documented, I was only able to find it in the configuration reference. The option allowing you to change the position of the web profiler toolbar in Symfony2:

    position: top

It accept 3 values: top, bottom and normal.

I think we can say thanks to Alexandre Salome for this feature, introduced 1 year ago!