Template Inheritance

Full Transcript

it's

welcome back to our Fostoria in this video where we speaking about them Blakey Harrigan's

it's a way we have to construct template buying heard and from older based

then show an example using the pie from the Oregon website

in this case I'm showing you the pie from the org website

if you look closely through different types of sections of

sides there will be things that are repeated so for example menu in each one of these patients look really similar

there will also be all there are similarities and we cannot see but for example the quarter

well it's similar in each one of them and also there will be the same static files and again a few other things are shared among the

so think about how you construct the template for each particular page

you couldn't be repeating the same code over and over and over what we want to do is create a more Cheryl template the basically holes they come on things and then we want to create a special %HESITATION in independent independent on specialized templates that basically current from that job base template we have created a before

let me show that in our code in this case where you some example fifteen so please go ahead and recommend it I just reloaded page and you'll see that it basically looks the same

date Marcia here is again down by the templates the template pull from the fifteenth example is

on thirteen here in this folder and it's cold child camp with

in this case what we're doing is we're following the low shake of her previous form a five bullet over you can see here what I have is that I'm thinking defy create more tipple forms in my web log

want to I want to repeat that book truck code over and over again

should I include the same %HESITATION pple link

HTML attributes archive to include the boats are file all over and over and over and over probably not what I want to do is create a base

HTML template that includes my product files and then for example to create these particular form but it Bob extending from that base template and that's exactly what we have

in this example

so right here I have today same template that I used to have before the same form but in this case I'm sure attempt from the base that HTML template in this case the paste up HTML it's just defines that basic structure and then it creates a Glock right so any template can that's fine bloke that he's

children are able to specialize or to rain implements right so in this case the base template just defines de basic HTML structure the title of the page

as Tadic pilots included and then it's set up or keep your

blog so that children can provide the content that they want to provide some in this case de lis park to your child these template Amy rendering race here will use the form that we have before to replace the park keep your call

usually a big application will be gone will consist on many many many different types of them blades on there will be multiple parents are

willing her to

%HESITATION but in this case we are showing you to buy the basic waves of

finding the firm blocks and also for you to understand

pay attention whenever you're grossing through example obligations to see how the templates are created it's real important to have %HESITATION are clear and clean struck