Welcome Guest, Not a member yet? Register   Sign In
Dynamic code in header view
#1

[eluser]tjans[/eluser]
Two questions:

1.) Currently, I have a header and a footer and on every content controller action, I render the header view, my content view for that controller action, and then the footer view. It's a lot of duplicated code...is there a best practice for handling this situation?

2.) If I have a header view that spits out a menu, and that menu is rendered based on some variables. What's the best practice for this situation. Currently it seems like you'd have to either run that code and pass it in on ever action that renders the view, or put the menu code into the view, which seems bad...
#2

[eluser]InsiteFX[/eluser]
MY_Controller

InsiteFX




Theme © iAndrew 2016 - Forum software by © MyBB