Return sfView::NONE in Symfony2

Posted February 20th, 2011 in Razno by Metod

In Symfony 1.x if you wanted to output some text or json or something else and not use a template for that action you would just do the following:

However, in Symfony2 that isn’t working anymore. Every action must return a response, so you can do the following:

Porting PHPEclipse syntax coloring to Eclipse PDT

Posted February 1st, 2011 in Razno by Metod

I was pushed into the “eclipse php world” with Eclipse + PHPEclipse setup. Although I knew about Eclipse PDT I never bothered to install it since PHPEclipse worked fine. Up untill I wanted to work with the newest PHP 5.3 features. PHPEclipse just doesn’t support that. So I had to move to PDT. It supports PHP 5.3 and is indeed a better tool. But what bothered me was the syntax coloring which is a bit different from PHPEclipse. So I’m publishing this “migration” post for anyone who has or will have the same problem. You can also use this guide to migrate to Zend Studio, since it is based on Eclipse PDT. Including me at some future time.

Eclipse PDT / Zend Studio:

  • Multi-line comment: #3F7F5F
  • Single-line comment: #3F7F5F
  • PHP tags: #FF0080
  • Keyword: #7F0055
  • Functions: #7F7F9F (no italic)
  • Variable: #7F7F9F
  • Parameter variables: #7F7F9F
  • Fields: #7F7F9F
  • Static fields: #7F7F9F
  • Superglobal variables: #7F7F9F
  • Internal constants: #7F0055
  • Constants: #7F0055
  • String: #2A00FF

Also in Zend Studio, line highlight is not the same as in PHPEclipse or Eclipse PDT.

  • Current line highlight: #E8F2FE

Apache configuration mistype

Posted December 6th, 2010 in Razno by Metod

This typo gave me some laugh. :)

httpd: Syntax error on line 559 of /usr/local/apache2.2.17/conf/httpd.conf: Expected </VirtualHost> but saw </Virtualbox>