The path variables are defined in the sfProjectConfiguration
and sfApplicationConfiguration
classes and stored in the sfConfig
object.
sf_root_dir # myproject/
sf_apps_dir # apps/
sf_app_dir # frontend/
sf_app_config_dir # config/
sf_app_i18n_dir # i18n/
sf_app_lib_dir # lib/
sf_app_module_dir # modules/
sf_app_template_dir # templates/
sf_cache_dir # cache/
sf_app_base_cache_dir # frontend/
sf_app_cache_dir # prod/
sf_template_cache_dir # templates/
sf_i18n_cache_dir # i18n/
sf_config_cache_dir # config/
sf_test_cache_dir # test/
sf_module_cache_dir # modules/
sf_config_dir # config/
sf_data_dir # data/
sf_lib_dir # lib/
sf_log_dir # log/
sf_test_dir # test/
sf_plugins_dir # plugins/
sf_web_dir # web/
sf_upload_dir # uploads/
Every path to a key directory is determined by a parameter ending with _dir
. Always use the path variables instead of real (relative or absolute) file paths, so that you will be able to change them later, if necessary. For instance, when you want to move a file to the uploads/
directory in an application, you should use sfConfig::get('sf_upload_dir')
for the path instead of
No comments:
Post a Comment