1. 04 Apr, 2011 5 commits
  2. 03 Apr, 2011 7 commits
  3. 02 Apr, 2011 3 commits
  4. 01 Apr, 2011 2 commits
  5. 31 Mar, 2011 1 commit
  6. 30 Mar, 2011 2 commits
  7. 29 Mar, 2011 6 commits
  8. 28 Mar, 2011 4 commits
    • Fabien Potencier's avatar
    • Fabien Potencier's avatar
      removed unneeded code · f7550e6b
      Fabien Potencier authored
      f7550e6b
    • Fabien Potencier's avatar
      added TranslationExtension · de9df3de
      Fabien Potencier authored
      Usage:
      
      $app = new Application();
      $app->register(new TranslationExtension(), array(
          'translation.class_path' => '...',
      ));
      
      $app['translator.messages'] = array(
          'en' => array(
              'apple' => 'apple',
          ),
          'fr' => array(
              'apple' => 'pomme',
          ),
      );
      
      $app['locale'] = 'fr';
      
      echo $app['translator']->trans('apple');
      
      If you use the Symfony Bridge extension, some tags and filters are also
      automatically available in templates:
      
      $templates = array(
          'index' => '{% trans %}apple{% endtrans %}'
      );
      de9df3de
    • Fabien Potencier's avatar
      added a SymfonyBridgesExtension · b550703b
      Fabien Potencier authored
      For now, it allows the Twig extension to register the Routing Twig extension:
      
      $app = new Application();
      $app->register(new SymfonyBridgesExtension(), array(
          'symfony_bridges.class_path' => '...',
      ));
      $app->register(new UrlGeneratorExtension());
      $app->register(new SessionExtension());
      $app->register(new TwigExtension(), array(...));
      
      You can now use {{ path() }} in templates to generate URLs.
      
      The order of registration of the extensions is significant.
      b550703b
  9. 27 Mar, 2011 10 commits