Question

I am writing an application using Symfony. I have some reusable components that I don't want to put into the main Symfony modules; instead, they are in the lib directory.

What I want to know is, what is the best way to include this file? Can I include lib/foo/bar.php or do I need a full path, or is there something else I should do?

Was it helpful?

Solution

I'm not an expert in Symfony, but these links should help You. Besides, because I am new to this forum, stackowerfolow lets me post just 1 link, so my second link will be explanation how to find it. ;)

  1. http://forum.symfony-project.org/index.php/m/92916/

  2. Google: The Definitive Guide to symfony 1.2 (should be still relevant) . There check the chapter 17 - "Extending Symfony" under the paragraph Plugins .

OTHER TIPS

you can use this to have the lib directory

sfConfig::get('sf_lib_dir')
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top