Welcome Guest, Not a member yet? Register   Sign In
Adding Menu into View page
#1

[eluser]Tanvir[/eluser]
Hello,m new to CI. I want to embed a custom MENU into a view file.
I have a template file where different views are added.
Code:
<?php// template .php
$this->load->view("includes/header");
$this->load->view("includes/leftNav.html");
$this->load->view($main_content);
$this->load->view("includes/footer");
?>
Now I have added the custom menu code to the leftNav.html file but its NOT working. But if I open the leftNav.html independently,it shows the menu well.But CI isnt showing the menu. Menu has its own javascript/images etc files in a separate folder.The menu is built by a menu-builder software. How should I add stylish menu into my CI page/views.
#2

[eluser]vbsaltydog[/eluser]
You don't use file extensions with the loader class.

... And why is it a .html when .php parses html and php code?
#3

[eluser]InsiteFX[/eluser]
move the css and js files to your header.php

And as vbsaltydog said change the leftNav.html to leftnav.php

These are all simple php and html coding...




Theme © iAndrew 2016 - Forum software by © MyBB