Jump to content

Photo
- - - - -

Classes inside application/libraries are not being loaded

libraries autoloader plugins

  • Please log in to reply
No replies to this topic

#1 davidballerini

davidballerini

    Level 1

  • Members
  • Level
  • 0 points
  • 6 posts

Posted 19 March 2018 - 11:02 PM

I've added a library to /application/libraries by following these steps:

- Developer SDK -> Create a Package (choosing type = Library)
- Added the library .tar skeleton via Package Manager -> Install New Package (all good and successful)
- I added the files containing the PHP classes of the library inside /application/Libraries
- tried to instantiate one of the classes from within a different module but I got this error:
 
2018-03-19T22:40:58+00:00 ERR (3): Error Code: 4247ae
Error: Class 'CamShowAPI' not found in /Applications/MAMP/htdocs/social-engine-4.10.1/application/modules/Livecams/controllers/CamshowController.php:9
 
Stack trace:
#0 /Applications/MAMP/htdocs/social-engine-4.10.1/application/libraries/Zend/Controller/Action.php(516): Livecams_CamshowController->webserviceAction()
#1 /Applications/MAMP/htdocs/social-engine-4.10.1/application/libraries/Zend/Controller/Dispatcher/Standard.php(308): Zend_Controller_Action->dispatch('webserviceActio...')
#2 /Applications/MAMP/htdocs/social-engine-4.10.1/application/libraries/Zend/Controller/Front.php(954): Zend_Controller_Dispatcher_Standard->dispatch(Object(Zend_Controller_Request_Http), Object(Zend_Controller_Response_Http))
#3 /Applications/MAMP/htdocs/social-engine-4.10.1/application/modules/Core/Bootstrap.php(84): Zend_Controller_Front->dispatch()
#4 /Applications/MAMP/htdocs/social-engine-4.10.1/application/libraries/Engine/Application.php(160): Core_Bootstrap->run()
#5 /Applications/MAMP/htdocs/social-engine-4.10.1/application/index.php(223): Engine_Application->run()
#6 /Applications/MAMP/htdocs/social-engine-4.10.1/index.php(25): include('/Applications/M...')
#7 {main}
 
Just in case, I then tried to:
- Developer SDK -> Build Package 
- delete the library
- add again the library using the newly built package so that all the files would be mentioned inside application/packages/library-camshow-4.0.0.json
 
Got the same error.
What am I doing wrong? How do I tell SE to load my LIbraries classes?






Also tagged with one or more of these keywords: libraries, autoloader, plugins

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users


All the resources listed here are just for testing purpose and they shouldn't be used at any commercial environment without a valid license.
Those are for users who wants to try them before buy. Help the developer to build it better by purchasing them from original authors.