edmundk Posted July 19, 2012 Report Posted July 19, 2012 Warning : call_user_func_array() expects parameter 1 to be a valid callback, class 'Mcars' does not have a method 'index' in /home/*****/public_html/*****/core/classes/MainController.class.php on line 218 Does anyone have any ideas? I got this error when writing my module. BTW it's for the Admin Center... Thanks, Edmund K. Quote
Moderators Kyle Posted July 19, 2012 Moderators Report Posted July 19, 2012 Edmund, The reason why of the error is that you don't have a function for the index. It's the way how module works, say you made a module called SomethingAdmin, and you type in the url with the SomethingAdmin, it will go directly to the index. If you have a different function, you can put this something like SomethingAdmin/itsnotindex. Examples... public function index() { //Its index! } public function itsnotindex() { //Its not index! } If you want more info. There's an example in the docs. -> http://forum.phpvms.net/page/index.html/_/developers-guides/creating-modules-and-add-ons-r25 Cheers! 1 Quote
edmundk Posted July 19, 2012 Author Report Posted July 19, 2012 Thanks Kyle. Your help is always speedy and reliable! - Edmund K. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.