mafflog
random stuff for teh interwebs
  • About
  • Projects
  • Archives
Home » 2012 » January

Enable Twig debug in Symfony2

January 13, 2012 · in Development, How-Tos, Snippets

To enable the debug tag in Twig, add the following to app/config/config_dev.yml

services:
    twig.extension.debug:
        class: Twig_Extensions_Extension_Debug
        tags:
            - { name: twig.extension }

Afterwards clear the cache and use the debug extension:

{% debug my_var %}

Sources

  • http://groups.google.com/group/symfony2/browse_thread/thread/40df2ca0b22b0166
github github github

Search

Categories

  • Android
  • Development
  • Fun
  • General
  • Hardware
  • How-Tos
  • Kitchen
  • Linux
  • No Comment
  • Projects
  • Server
  • Snippets
  • Software
  • Video
  • Web
  • Windows
  • Wordpress

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Copyright © 2008-2013 mafflog