It looks like your include_path doesn't have "." in it, so files in the same directory as the current script are not found. You can check the include_path like this:
debug( explode( PATH_SEPARATOR, get_include_path() ) ); If, for some reason, you cannot change the include_path, you could modify the vendor file with: include(__DIR__.DS.'k_file_name.php'); This will prefix the script name with the full path from root. On Wed, Jun 20, 2012 at 6:50 AM, hoss7 <[email protected]> wrote: > hi > i have some vendor files > 1.app/vendors/p/p.php //class file > 2.app/vendors/p/pc.php //config for class > 3.app/vendors/p/pk.php key for class > > i have insert "p" in my controller: > App::import('Vendor','p/p'); > > and i am create some object from this class > > $cart= new pcct($somedata); > > now my problem: > > in class pcct i have some function like this: > > function s($value){ > > include 'pc.php'; > > 1: $k=file_get_contents($k_file_name); > > } > > when i am call controller i see this error: > line 1: faild to open stream: no such file or directory. > > Note: in pc.php i have some value for file name for pass to this function > and all file are in same place. > > in pc.php i have : $k_file_name='pk.php'; > > how can i config $k_file_name path for this function to access that file > > -- > Our newest site for the community: CakePHP Video Tutorials > http://tv.cakephp.org > Check out the new CakePHP Questions site http://ask.cakephp.org and help > others with their CakePHP related questions. > > > To unsubscribe from this group, send email to > [email protected] For more options, visit this group at > http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/cake-php
