Symfony: Delete an Application

Home -> Programming -> Web -> Symfony

2230 views

From the computer of: qmchenry (339 recipes)
Created: Apr 06, 2008     Updated: Apr 07, 2008


Add a comment

Add to:
Add to stumbleuponAdd to del.icio.usDigg itAdd to FURL

The command line provisioning utility in symfony provides mechanisms to create an application, but doesn't have the means to delete one. If you've unintentionally created an application or no longer need an app and want to do housecleaning, this Tech-Recipe describes how to get it gone.

To delete a symfony application, you just need to delete the application directory and the front controller scripts. For example, if your application is named 'testapp' you need to delete the following directory and all of its contents:

apps/testapp


The front controllers are created in the web/ directory. Two are typically created for new applications, one for production and one for development. Continuing the example above, to delete the controllers for the application 'testapp' you must delete these files:

web/testapp.php
web/testapp_dev.php


All of the files and directories referenced above are contained in the symfony installation (meaning if you have created the application, you should know where these files are). One caveat in deleting the front controller scripts: if you are deleting the first application you created or is the current default application, the production controller is named index.php instead of testapp.php. While you can delete the index.php file, this may have undesirable effects for web requests that do not explicitly reference a controller script. In this case, you can edit the web/index.php file and replace the name of the application (testapp) on the line starting define('SF_APP', with the name of the application you want to run by default.

Subscribe to the Tech-Recipes Newsletter

You can get tips like this delivered in your email every week!

Enter your Email

We will never, ever sell your email address or spam you.





Related recipes:

  Symfony: Rebuild from Schema.yml Without Loss of Data
  Symfony: Troubleshooting file uploads
  Symfony: Fix propel-insert-sql error: Can't connect to local MySQL server
  Symfony: Add log message manually
  Symfony / Propel: How to Left Join

 

Sponsored links

 

Login

Nickname

Password

Don't have an account yet? You can create one. As a registered user you have some advantages like theme manager, comments configuration and post comments with your name.