yuxunbin / yafphp

Automatically exported from code.google.com/p/yafphp
0 stars 0 forks source link

Uses of namesapces for php 5.3 #5

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. activate yaf.use_namespace (I tried with ap.use_namespace too) in ini file
2. change in index.php to $app  = new Yaf\Application(APPLICATION_PATH . 
"/conf/application.ini");

What is the expected output? What do you see instead?

and the results is: 

Warning: could not find script 
/home/user/websites/test/yaf/application/library/Yaf/Bootstrap/Abstract.php in 
/home/user/websites/test/yaf/application/Bootstrap.php on line 4 Call Stack: 
0.0002 328488 1. {main}() /home/user/websites/test/yaf/index.php:0 0.0003 
339316 2. Yaf\Application->bootstrap() /home/user/websites/test/yaf/index.php:7 
0.0004 343128 3. Yaf\Application->bootstrap() 
/home/user/websites/test/yaf/index.php:7 Fatal error: Class 
'Yaf_Bootstrap_Abstract' not found in 
/home/user/websites/test/yaf/application/Bootstrap.php on line 4 Call Stack: 
0.0002 328488 1. {main}() /home/user/websites/test/yaf/index.php:0 0.0003 
339316 2. Yaf\Application->bootstrap() /home/user/websites/test/yaf/index.php:7 
0.0004 343128 3. Yaf\Application->bootstrap() 
/home/user/websites/test/yaf/index.php:7 

What version of the product are you using? On what operating system?

Please provide any additional information below.

in the Bootstrap.php:
 class Bootstrap extends Yaf_Bootstrap_Abstract can't be changed into 
 class Bootstrap extends Yaf\Bootstrap\Abstract

 I looked into svn and into yaf_controller.c you have YAF_INIT_CLASS_ENTRY(ce, "Yaf_Controller_Abstract", "Yaf\\Controller_Abstract", yaf_controller_methods);
 in the yaf_bootstrap.c you have YAF_INIT_CLASS_ENTRY(ce, "Yaf_Bootstrap_Abstract",  "Yaf\\Bootstrap\\Abstract", yaf_bootstrap_methods);

Thankyou

Original issue reported on code.google.com by vivianbo...@gmail.com on 24 Nov 2011 at 9:25