Table of Contents for
Drupal 8 Quick Start Guide

Version ebook / Retour

Cover image for bash Cookbook, 2nd Edition Drupal 8 Quick Start Guide by J. Ayen Green Published by Packt Publishing, 2018
  1. Drupal 8 Quick Start Guide
  2. Title Page
  3. Copyright and Credits
  4. Drupal 8 Quick Start Guide
  5. Dedication
  6. Packt Upsell
  7. Why subscribe?
  8. Packt.com
  9. Contributors
  10. About the author
  11. About the reviewers
  12. Packt is searching for authors like you
  13. Table of Contents
  14. Preface
  15. Who this book is for
  16. What this book covers
  17. To get the most out of this book
  18. Download the color images
  19. Conventions used
  20. Get in touch
  21. Reviews
  22. Finding Your Way around Drupal
  23. Installing Drupal
  24. Readying the environment
  25. Running the Drupal installation script
  26. Site information
  27. Site maintenance account
  28. Regional settings
  29. Update notifications
  30. The behind-the-scenes tour
  31. Administration menu
  32. Tabs
  33. System message area
  34. Search widget
  35. User menu
  36. Main navigation
  37. Main content area
  38. Summary
  39. Structuring Content Types
  40. What is content?
  41. Content as fields
  42. Understanding content types
  43. Defining the content type
  44. Submission form settings
  45. Publishing options
  46. Display settings
  47. Menu settings
  48. Managing content type fields
  49. Designing a content type
  50. Content type settings
  51. Fielding the content type
  52. Field types
  53. Our content type field
  54. Adding fields to the content type
  55. Summary
  56. Managing Users
  57. User types
  58. User roles
  59. Managing permissions
  60. Users
  61. Creating a user account
  62. Summary
  63. Creating and Editing Content
  64. Using the WYSIWYG editor
  65. Title*
  66. Body
  67. Summary Field
  68. Body text
  69. Text format
  70. Tags
  71. Images
  72. Publishing the content
  73. Additional settings
  74. Revision log message
  75. Menu Settings
  76. Comment Settings
  77. URL Path Settings
  78. Authoring Information
  79. Promotion Options
  80. Completing the process
  81. Summary
  82. Making Drupal Even More Useful
  83. Pathauto
  84. Paragraphs
  85. Content moderation
  86. States
  87. Transitions
  88. Workflow application
  89. Summary
  90. Grabbing Global Readership
  91. Declaring additional languages
  92. Translating content
  93. User language selection
  94. Translating the user interface
  95. Summary
  96. Feeding the Masses – RSS
  97. Why feeds?
  98. Selecting content for a feed
  99. Modifying content for feed selection
  100. Pick-me flags
  101. Tags
  102. Views
  103. Creating the container view
  104. Creating the Pets feed
  105. Display name
  106. Title
  107. Format
  108. Feed settings
  109. Filtering the criteria
  110. Sort criteria
  111. Creating the Travel feed
  112. Title
  113. Feed settings
  114. Format
  115. Filtering criteria
  116. Creating the Leftovers feed
  117. Title
  118. Feed settings
  119. Format
  120. Filtering criteria
  121. Creating the Feed Links block
  122. Summary
  123. Welcome Home!
  124. BAD home page!
  125. Design improvements
  126. Too much content!
  127. No access to content
  128. No RSS feeds menu
  129. We need a Terms and Conditions page
  130. Making the changes
  131. Improving the Frontpage view
  132. Title
  133. Format
  134. Fields
  135. Filtering criteria
  136. Block settings
  137. Pager
  138. Adding an Archive
  139. Adding the RSS Feeds menu
  140. Fixing the Footer menu
  141. Summary
  142. Other Books You May Enjoy
  143. Leave a review - let other readers know what you think

Managing permissions

Any page element that a user can view or hear or otherwise interact with, such as a menu link, is available for doing so because the user, via a role, has been given permission to do so. This is a very important concept, so I will give an example. You have no doubt seen a Terms and Conditions link on most sites.

On a Drupal site, if you see such a link, it is because your user role has been granted permission to access that content (the Terms and Conditions page). Were that permission not granted for your user, the link would probably not be visible. Were it still visible, or were you to enter the URL for the page in your browser, you would receive a message stating that you have not been granted access to that content. 

Because permissions can be granular and detailed, there are a lot of them, and adding modules will typically add more to the list. We're going to focus on a subset of them to keep things simple.

With that warning, let's take a look by clicking the Permissions tab at the top of the page, which will take us to admin/people/permissions.

The structure of the permissions page is all permissions provided in a scrollable table. Across the top of the table are the roles defined on the site. You'll see that they are the same as those that were listed earlier. Down the left-most column of the table is the list of permissions for actions categorized by alphabetical topic and/or name of the module that defines them. 

The manner of management is quite simple. If a box is checked, that column's role has the listed permission. For example, looking at the first permission, which is associated with the Block module, the ability to Administer blocks has been granted only to those users having the Administrator role.

Rather than scroll down and up for each of the roles, we'll approach this by permission, so that we only have to scroll once. In the following table, I will provide each of the categories and permissions within it that require our attention, as well as what the checkboxes should look like after you have checked the appropriate ones to accomplish the grants we defined earlier for our roles.

We will not be changing any of the settings in the Administrator column, but I have included it so that the relative position of each role is as you see it on your screen.

I will only provide rows for those permissions that require a setting change. For example, you will notice under the category of Comment that already all authenticated user types have the ability to post comments, while Anonymous users have the ability to view comments, so no changes are needed, which is why that row won't appear in this table:

Category/Permission

Anonymous

User

Authenticated

User

Administrator

Client

Consultant

Editor

NODE

    Appointment: Create new content

x

 

x

    Article: Create new content

x

x

    Appointment: Delete own content

x

x

    Article: Delete own content

x

x

    Article: Edit any content

x

x

    Appointment: Edit own content

x

x

    Article: Edit own content

x

x

    Access the Content overview page

x

x

x

    View own unpublished content

x

x

x

 

Most of the permissions in the preceding table relate to CRUD operations on specific content types. That is, being able to create (add), edit (update) and delete content of a specific type, such as the Appointment type that we created. You can see that we granted permission to perform such operations to Consultants, but not to Editors, whereas we granted permission to perform those same operations on Article content to Editors, but not to Consultants.

Access rights, permissions, take effect immediately. That is, even if you have permission to perform a certain action or access a type of content, were that permission to be removed from your role, your access to that action/content would then be gone, unless and until it is reinstated.

You will notice that some of the permission descriptions look very similar, such as:

  • Appointment: Edit own content
  • Appointment: Edit any content

The difference between the two is that with the second, the user is able to edit Appointment content regardless of who created it, whereas with the first, the user needs to have created it. 

The final permission, View own unpublished content, is worth noting as well. Unless this permission is granted, if a new piece of content is saved as unpublished, its author can no longer access it, only being able to access content marked published. With this permission, the user can also access his unpublished content, which is necessary for working with drafts.

You might also notice that permissions for reading/viewing specific content types were not present. That is because, while there is a permission for viewing published content, that is as granular as the permissions get for viewing content; there are no permissions regarding viewing a particular content type. There is, however a module that provides those permissions, which we will add in Chapter 5, Making Drupal Even More Useful. Once we have those permissions available to grant, we can ensure that only the roles we select can comment on a specific content type, because if you can't view the content, you can't comment on it!