Snippets

Create an account or login to be able to add, comment and rate snippets.

Navigation

Hide debug screen by actions.

If you do not want to display debug screen (Ajax or feed etc),add following code each action.

sfConfig::set('sf_web_debug', false);
by Yoshihiro TAKAHARA on 2006-05-22, tagged debug 

Comments on this snippet

gravatar icon
#1 Fabien Potencier on 2006-05-22 at 08:13

The web debug toolbar is automatically hidden when one of the following is true:

  • action called via Ajax
  • response content type different from text/html
  • response status code is 304
gravatar icon
#2 Yoshihiro TAKAHARA on 2006-05-22 at 12:27

Thanks. I understood well. This is a good mechanism.

You need to create an account or log in to post a comment or rate this snippet.