Creating Your First Template With CodeIgniter

preview_player
Показать описание
Creating Your First Template With CodeIgniter
Рекомендации по теме
Комментарии
Автор

I also like to set an isset extended_header template file path in the header in case I need to include different scripts for certain pages. It helps keep the main header clean and only load resources if they are needed.

halibuthero
Автор

Excellent Explanation.Dude I really like that the way explained. Your way is clean, cut and neat.please upload similar like for other topics. keep Doing...

jkpatel
Автор

gooood job, i use this simple function to make an easy templates in code ignater :


function myTemps($main, $data, $tempName='template')
{
$temp['main']=$main;
$temp['data']=$data;
$this->load->view($tempName, $temp);
}

After your work i make this to switch the template .

Now i need how to add in this template a compiled viewer like last_news panel or last connected user ??!!


tukteek
Автор

This is what i was looking for! Thank you very much for this tutorial

VinKing
Автор

so my question is, how do i incorporate my external stylesheet files into this? this video was exactly what i needed today.

highvltage
Автор

Can you please show a tutorial for SEO friendly urls? I managed to remove index.php from the url through .htaccess.

But now I have a shopping cart where I want to show products like


Please help.

webglobesolutions
Автор

great job, but its broke the mvc pattern...
you can load in your controller function the view with a custom layout library...

$data["header"] =
$this->layout->view("view", $data);




chlno
Автор

Can you change the title of the page for each page and how would you do that? Or do they have to be the same?

I really liked this video :)

washedtoohot
Автор

nope it does not broke the pattern. it makes the mvc more clearer since you don't want to make controller messed up by views.

LetsSpotIt
Автор

This seemed to work but how do I get it to load the stylesheet.. which is in the includes folder with the header file..

DavidMacAree
Автор

can you please make full structure of complete project to load css, js files and all things you know better.

learnwithshoaib
Автор

you are awesome instructor . this tutorial is really helpful for me i was searching from one week about such type of help you are great.

learnwithshoaib
Автор

hi Jeffrey, I have a question.
Are so many template libraries available for codeigniter.

What do you advice? Should we stick with basic codeigniter as presented in this video or with a template library?

costicanu
Автор

You should not put any PHP code in your views. As MVC suggests, those are for Views only. What you do needs to be put in the Controller.

It's an easy way of doing it, but it breaks the entire purpose of MVC design.

TotallySD
Автор

Thank you for an awesome video, can you please share some real time example of integrating theme of a real website in codeigntor .

imadafzal
Автор

@tukteek update :)

function myTemps($main, $data=Null, $tempName=­'template')

it's not necessary to have data to send

tukteek
Автор

very good tutorial nice and straight forward thanks

stephencooper
Автор

i love how you code, its like experienced. fast and to the point.

masbro
Автор

Very nice tutorial, but your keyboard is ANNOYING!

trhwallst