Drupal 8 - How To Use Views Header And Footer

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hey guys so in this tutorial we focus on this area here so when we created this view we already set the path to home so we don't have to change that and the menu item is already defined for the front page so we don't have to define the item here you can find the menu items here at structure menus and main navigation here we have the home link that points to the front page so let's change the access permissions for this view so that only administrator roles can access it so hit this permission link here and select a role apply and select the role here we want to select the administrator role and apply so now if you call the front page and log out then we shouldn't see any items here like this so now let's login back and if you edit the admin user of course this main user has to administrator role in here so we can see those items in this area here you can add stuff on top or bottom of the view so let's add a result summary it add here and select result summary and apply so here are some tokens you can use here and let's use this default setting and see how it looks like so now we can see the summary on top this tells us that we are looking the first 10 items of total of 28 items and of course this changes when we go to the next page like that so let's add something else for the folder so for example you could add this conduct block this contact link here so click Add so here you can see that we can add all kinds of things here but let's select the rendered in the d-block and for the block ID we will use the machine name of the block so you can see it if I hover over it is you can see it in the bottom here but you can edit it also and we see it here or if you go to the blocks page you can also see it at the bottom like that and apply and you might want to use some more descriptive text here so let's click this and change this administrative title to contact link like that and let's save this and here we have the contact link next let's change the no results behavior change the filter criteria here the plus two hours so now we shouldn't see any items here as you can see but we can also add some text here so let's do that click the Add button here and let's select global text area text area and here we can select some tokens if we want let's use the view title and apply so now when we refresh this you can see this custom message here so here you can change the page settings but first let's change this back so we can see some items like this so currently the pager looks like this but you can change these texts so let's do that let's hit this link here and that's so only six items per page and delete these texts here and apply and if you want to make it more attractive of course you can use CSS to style it and the small link here allows you to link to the page display if you have multiple displays but more about that in the displays tutorial okay that's it thanks for watching if you like this video please like share subscribe and comment see you in the next tutorial bye
Info
Channel: Samuli Natri
Views: 12,220
Rating: 4.9230771 out of 5
Keywords: WDTutorials.com, wdtutorials, web, design, development, tutorials, tutorial, Web Development (Industry), video, instructional, Drupal, Drupal 8, Article, Video, Views, Page, Header, Footer
Id: dJD7GZanDuY
Channel Id: undefined
Length: 5min 43sec (343 seconds)
Published: Fri Dec 04 2015
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.