Jump to content

how can i call a module from a FrontController


edgaralfonso

Recommended Posts

Hi guys.

 

I have a Module class in: /modules/something/something.php

 

And i have to call that in a FrontController class located in: /Controllers/SomeController.php

 

So I do a new instance of object:

 

$menunav = new SomeThing;

 

But doesnt work.

 

 

Could you help me please

 

Thank you.

Edited by edgaralfonso (see edit history)
Link to comment
Share on other sites

Solved

 

class MyControllerCore extends FrontController{
.
.
.
.
public function preprocess(){
$object = ModuleCore::getInstanceByName("blockmanufacturer");
//return HTML of blockmanufacturer module of the hook footer
return $module->hookFooter();
}

}

 

 

works fine ;D

Edited by edgaralfonso (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...