Archive for the ‘Symfony’ Category

Symfony Troubleshooting - Form Class Not Found

Friday, April 3rd, 2009

Troubleshooting:
When attempting to create a backend module with the Propel utility:
XXXXXXXForm class not found

Solution
[possibly you need to delete the files in lib/model/om, or maybe even the whole lib/model directory]
symfony cc
symfony propel:build-forms
symfony cc

Symfony - Propel - Using A Prefix For The Tables But Not For The Classes

Friday, April 3rd, 2009

What we want is to have a prefix for the database tables (for example, blog_) but not for the classes generated by Propel. That is, we want Post and not BlogPost as the name for the class.

We can achieve that, by this schema.yml:

blog_post
  _attributes: { phpName: Post }
  id: ~
  content: longvarchar

Symfony - Difference Between a Live and a Non-live Environment

Sunday, July 27th, 2008

What makes an environment a live one or not is the frontend. In particular the third param of the method:
ProjectConfiguration::getApplicationConfiguration
If we are in a live environment, instead of displaying the full execution stack and an explicit error message, the page error500 will be displayed

Symfony - Enable the Compatibility with the Version 1.0 - Good for forms Generation

Sunday, July 20th, 2008

This solves errors like:
Fatal error: Call to undefined function form_tag()
Fatal error: Call to undefined function input_tag()

File apps/your_application/config/settings.yml
Set:
compat_10: on
(be careful with the indentation!)