Welcome Guest, Not a member yet? Register   Sign In
Dynamic Menu
#1

[eluser]morfasto[/eluser]
Hello All,

I wanted to know where do I have to set a variable with the menu information got from the database so that I dont have to declare it on every method on every controller to send it to the view. I want to make a dynamic menu.

Any recomendations?

Thanks in advance!
#2

[eluser]PravinS[/eluser]
you can define menu variable in config.php file and to load dynamic menu you can create one template in view and can include header, menu, footer etc.
#3

[eluser]morfasto[/eluser]
Is it possible to call a method of a model from config.php?
#4

[eluser]PravinS[/eluser]
no you cannot, what kind of variable you want to set?
#5

[eluser]morfasto[/eluser]
An array with information from the DB




Theme © iAndrew 2016 - Forum software by © MyBB