• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Class MY_ not found


i have a little problem

i have inherited a Codeigniter project who does not work ,and i did not find a solution
the error is Fatal error: Class 'MY_Benchmark' not found in system/codeigniter/Common.php on line 130

MY_Benchmark class is put in application/libraries and is created correctly

please help me

Try to put it in /application/core/ i think you have extended the CI_Benchmark class.


thank you for replay ...i am using codeigniter 1.7.3 and there is no application/core folder,should i create it ? is true that CI_Benchmark is extended

Hi djcata,
I recommend using version 2.2. It is the most stable version and most recently for the production. Surely with this version does not have that problem.

As Smith wrote you shoul user at least CI 2.2 or better CI 3.


thank you

i know that it would be better with newer version , but project was developed with older one and i am not sure how many changes has to be made to upgrade

anyway it seems that if i put <?php in place of <? at the beginning of the file this error goes away

Yes for php files you have always to open the content with <?php to call the interpreter to parse it as php.


yes but i did not realize that , there are a lot of files there , didn't checked all

now i have another error : i get call to undefined function and if i comment that code i get the next error Non-existent class: Session

Have you loaded the session library in config.php


i have this in autoload.php :
$autoload['libraries'] = array('database','session','user_agent','image_lib','MP_Cache','Assets');

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.