1
00:00:00,240 --> 00:00:05,940
Hello, friend will come back in a previous video, I have discussion about that you are patterns.

2
00:00:06,150 --> 00:00:12,150
So now in this video, I want to discuss about one of the most important part in Django, that is include

3
00:00:12,150 --> 00:00:12,720
Methode.

4
00:00:13,170 --> 00:00:16,720
So how can working with this include Methode in this video?

5
00:00:16,740 --> 00:00:19,250
I will show you that things with a live example.

6
00:00:19,680 --> 00:00:21,260
So now for better understand.

7
00:00:21,270 --> 00:00:23,960
So that is one of the bootstrap of the template.

8
00:00:23,970 --> 00:00:26,110
OK, so that is one of the bootstrap templates.

9
00:00:26,110 --> 00:00:32,580
So here for our this fundamental project, I want to use this theme so into this theme area, you can

10
00:00:32,580 --> 00:00:33,500
actually download it.

11
00:00:33,510 --> 00:00:35,170
So I will discuss about that later.

12
00:00:35,190 --> 00:00:40,260
Right now I just simply preview this team, simply the theme area here.

13
00:00:40,260 --> 00:00:44,200
You can see they have all that in our home page and into the home homepage area.

14
00:00:44,220 --> 00:00:45,890
They have one of the slides, right.

15
00:00:45,900 --> 00:00:47,170
So that is the slider.

16
00:00:47,340 --> 00:00:51,980
So slide the maximum time actually display only into the home page.

17
00:00:51,990 --> 00:00:57,840
But if you go to about space in there, about the space here, you can see our header is the same and

18
00:00:57,840 --> 00:01:02,120
also Futer is the same, but there have no slider.

19
00:01:02,130 --> 00:01:07,290
But if you go to that home base and the home page, you can see there is a clever header is the same

20
00:01:07,290 --> 00:01:08,970
and the future is the same.

21
00:01:09,180 --> 00:01:13,560
And but there have only one of the include one of the things that the lower slide.

22
00:01:13,650 --> 00:01:13,960
Right.

23
00:01:14,220 --> 00:01:16,260
So now we can actually add this type up.

24
00:01:16,260 --> 00:01:20,190
Another one of the part you would using that include.

25
00:01:20,190 --> 00:01:26,420
But I assure you everything will be more clear to you like that is our base and the base area.

26
00:01:26,430 --> 00:01:32,310
I have already put that link as a home that they are about a space that is a contact space and there

27
00:01:32,310 --> 00:01:33,190
is a profile page.

28
00:01:33,600 --> 00:01:37,350
So now if you open our layouts, that is in our layout.

29
00:01:37,350 --> 00:01:41,070
I have already added that our this Napat in our layout area.

30
00:01:41,520 --> 00:01:44,810
So don't go to our project and the project area.

31
00:01:44,820 --> 00:01:48,360
If you go to our template, it is a template that is all layout.

32
00:01:48,360 --> 00:01:48,720
Right.

33
00:01:48,990 --> 00:01:50,040
See the layout.

34
00:01:50,040 --> 00:01:51,860
So here that is our neighbor.

35
00:01:52,620 --> 00:01:56,340
So that is our neighbor and then that is our block.

36
00:01:56,370 --> 00:01:59,930
That means the block content side of the block content area here.

37
00:02:00,360 --> 00:02:09,530
If you added all of the H1 tag and I just name it as a this is a slider part, OK?

38
00:02:09,570 --> 00:02:12,120
I just name it as a this is a slider part.

39
00:02:12,420 --> 00:02:19,590
And now if you click as a Savol and now if you refresh it now you can see they have that other part

40
00:02:19,590 --> 00:02:22,230
is added as a this is a slider part.

41
00:02:22,590 --> 00:02:28,470
But here I don't I only want to visible our slider part for our home page, not the about page.

42
00:02:28,470 --> 00:02:33,200
But if you go to that, our about page you can see into the about face also is added.

43
00:02:33,610 --> 00:02:38,970
That is a contact page that is also displayed on here and also is displayed in our profile page.

44
00:02:39,570 --> 00:02:41,270
I hope you can understand about it.

45
00:02:41,460 --> 00:02:45,990
So here I only want to display our this slider part for our home base.

46
00:02:46,140 --> 00:02:51,540
So if you want to do this type of work, then you can do this work with using that include method I

47
00:02:51,540 --> 00:02:52,050
show you.

48
00:02:52,050 --> 00:02:58,740
Then everything will be more clear to you for doing this in our project into the project templates so

49
00:02:58,770 --> 00:03:02,970
that the template area, I create new file and I just name it as a slider.

50
00:03:04,500 --> 00:03:06,850
OK, this slider dot SGML.

51
00:03:07,530 --> 00:03:10,980
So now here I want to do I want to add our this text.

52
00:03:10,980 --> 00:03:13,550
OK, so I just simply got it from here.

53
00:03:13,560 --> 00:03:18,570
That is from a layout toters Temel and I or Slider and the slider area.

54
00:03:18,570 --> 00:03:19,750
I just simply passed it.

55
00:03:20,130 --> 00:03:25,470
So now if you click as a Savol so now it's not should be visible like a refresh.

56
00:03:25,470 --> 00:03:30,740
Now this is totally clean and if you go to about a space that is also a liquid.

57
00:03:31,050 --> 00:03:36,870
So now I want to do I want to load our this takes that means our this slider dot estimate.

58
00:03:36,990 --> 00:03:39,200
This takes in our space.

59
00:03:39,210 --> 00:03:41,510
I want to display in our homepage right.

60
00:03:42,030 --> 00:03:42,720
For the home.

61
00:03:42,720 --> 00:03:46,020
I have already added that link.

62
00:03:46,020 --> 00:03:51,560
So that means if you go to our main portfolio into the main portfolio area, that is you.

63
00:03:51,600 --> 00:03:52,200
What else.

64
00:03:52,410 --> 00:03:53,670
And that is our home.

65
00:03:53,670 --> 00:03:56,310
Right there is a home where there is a view.

66
00:03:56,310 --> 00:04:01,010
I just loaded our on the function as a home function and there is our department.

67
00:04:01,410 --> 00:04:08,550
So if you go to our views and the home so that it means there is a views and there is our home here,

68
00:04:08,550 --> 00:04:12,060
I loaded our index statistical right index.

69
00:04:12,210 --> 00:04:14,220
This is our main home base.

70
00:04:14,490 --> 00:04:18,630
So now if we go to our template and the template, that is our indexed estimate.

71
00:04:19,170 --> 00:04:21,120
So you do that in this e-mail here.

72
00:04:21,120 --> 00:04:26,190
I want to do I want to include our slider, OK, this slider dot e-mail.

73
00:04:26,190 --> 00:04:32,730
I want to simply put it on here, then automatically it should be visible in our particular that area.

74
00:04:32,730 --> 00:04:38,790
That means in our home base, I show you like here, if you want to include it, you have to include

75
00:04:38,790 --> 00:04:41,000
it in particular this blog area.

76
00:04:41,010 --> 00:04:47,700
OK, make sure you included this block content area C block content area here.

77
00:04:47,700 --> 00:04:49,230
I want to do I want to include it.

78
00:04:49,230 --> 00:04:54,030
So if you want to include first of all, there is a color bracket and then the double person is and

79
00:04:54,030 --> 00:04:56,190
then you have to added that include.

80
00:04:58,260 --> 00:05:05,220
OK, that means to include and include our whose file include our dislike that that we decided not to

81
00:05:05,400 --> 00:05:05,730
file.

82
00:05:05,760 --> 00:05:08,790
I want to include OK, so I just simply named that are fine.

83
00:05:09,270 --> 00:05:11,040
So that is into the same pot.

84
00:05:11,070 --> 00:05:17,820
So for the reasons here, I just simply added as a slider, slider, dot astm.

85
00:05:17,820 --> 00:05:20,660
All right.

86
00:05:20,670 --> 00:05:26,610
So that is actually small so that the slider daughter's table that is decided against either simply

87
00:05:26,610 --> 00:05:27,810
in good on here.

88
00:05:28,260 --> 00:05:29,560
So now let's check this out.

89
00:05:29,580 --> 00:05:33,120
If you click on the save all so that is our index, not the CML.

90
00:05:33,720 --> 00:05:36,480
And now if you refresh it, yes, you can see Fehn.

91
00:05:36,750 --> 00:05:41,100
Now, our slider dot e-mail is perfectly loaded on here.

92
00:05:41,250 --> 00:05:47,880
But if you now go to our aboutus, you can see if the about Espace here, they have no slider because

93
00:05:47,880 --> 00:05:48,660
of all here.

94
00:05:48,660 --> 00:05:50,600
I didn't include any slider.

95
00:05:50,610 --> 00:05:52,180
So there is a contact space there.

96
00:05:52,200 --> 00:05:56,620
The profile pages, everything is clean but only in our home page area.

97
00:05:56,640 --> 00:05:59,180
I include our this part that in this slide.

98
00:05:59,280 --> 00:05:59,550
Right.

99
00:05:59,940 --> 00:06:03,600
So if you want to like better I want to update it.

100
00:06:04,140 --> 00:06:05,910
Cerveteri just simply copy it.

101
00:06:06,160 --> 00:06:07,710
OK, just simply copy it.

102
00:06:07,710 --> 00:06:10,580
And now that is one of the class actually.

103
00:06:10,590 --> 00:06:12,120
So better here.

104
00:06:12,810 --> 00:06:18,930
Here I want to actually report on the day of class and I just put that name as a Jumbotron and H1 tag

105
00:06:18,930 --> 00:06:25,230
area and they together to do and actually cart it and here I just simply name it.

106
00:06:25,560 --> 00:06:29,860
OK, I just simply name it then actually we'll look at it.

107
00:06:30,030 --> 00:06:32,550
So here I just simply add this part.

108
00:06:33,000 --> 00:06:38,070
And now if you click as I save all, so now it should be one of the blog actually.

109
00:06:38,250 --> 00:06:40,020
So here if you can get the refresh.

110
00:06:40,410 --> 00:06:40,800
Yes.

111
00:06:40,800 --> 00:06:41,300
You can see.

112
00:06:41,640 --> 00:06:45,590
So this is our slider part and that is our home page detail.

113
00:06:45,600 --> 00:06:49,550
So if you go to our about he did about the space that have no slider.

114
00:06:49,560 --> 00:06:49,890
Right.

115
00:06:50,390 --> 00:06:52,770
So Subframe, I hope is very much clear to you.

116
00:06:52,770 --> 00:06:54,580
How can include any file.

117
00:06:54,690 --> 00:07:01,740
So here with this, you have to make sure you have to add that things in that we include all the file

118
00:07:01,740 --> 00:07:03,270
into the block content area.

119
00:07:03,510 --> 00:07:08,850
So the the block content area, I simply include one of the slider noticed html with our this include

120
00:07:08,850 --> 00:07:09,160
method.

121
00:07:09,720 --> 00:07:10,340
OK, different.

122
00:07:10,710 --> 00:07:12,840
So that's how you can actually do that work.

123
00:07:12,870 --> 00:07:18,390
So if you want to display it, if you want to displayed in our profile piece, like if you go to our

124
00:07:18,390 --> 00:07:19,950
employees there is a profile.

125
00:07:20,230 --> 00:07:20,570
Right.

126
00:07:21,210 --> 00:07:23,240
So now there is a profile of this Jammal.

127
00:07:23,250 --> 00:07:26,960
So if you now go our profile so they have no file.

128
00:07:26,980 --> 00:07:32,850
So if you want to displayed on here, you can display I just simply include our slider dot e-mail for

129
00:07:32,850 --> 00:07:35,010
our profile basically of the save all.

130
00:07:36,100 --> 00:07:41,770
Refresh it here, you can see it's a perfectly display if you go to the contact, it's not displaying

131
00:07:41,770 --> 00:07:43,160
on here, there is a profile.

132
00:07:43,720 --> 00:07:49,510
So, Fred, I think its concept is very simple, but is very much important on the part which will be

133
00:07:49,510 --> 00:07:51,490
needed for this project.

134
00:07:51,730 --> 00:07:52,120
OK.

135
00:07:52,600 --> 00:07:55,180
No, I just simply deflect it from here.

136
00:07:55,540 --> 00:07:56,320
Refreshing.

137
00:07:56,320 --> 00:07:57,810
It is totally gone.

138
00:07:57,820 --> 00:07:58,620
Go to home.

139
00:07:58,810 --> 00:08:05,110
Only our home base area outside our base is visible, you know, next video and discussion about how

140
00:08:05,120 --> 00:08:07,830
can rendering the context in your template.

141
00:08:08,110 --> 00:08:09,720
So thanks for watching.

142
00:08:09,770 --> 00:08:11,650
I will see you in the next video.
