[eluser]Stylec[/eluser]
Hi, I'm trying to port a site to CI and am looking for ways to do the following.
At present i have a site that has the template coded into the index.php file, I then just use include('topnews.php') to show the topposts from the forums where ever i want.
In topnews.php i get the news from the DB and then pass them to a html template file. This then gets displayed on the index.php file like a block on the left or right side.
In CI i am thinking of having it like this-
Use matchbox to add module support. Have a module called news. Then have a controller called news_block that calls the news_block_view but how do i call the news_block from the main template file just like i did with the include.
Maybe the structure as shown.
modules
-news
--controllers
news_block.php
--views
news_block_view.php
views
-themes
--default
theme.php
Thanks for any help.