Skip to main content
Top

2015 | Book

Beginning Drupal 8

insite
SEARCH

About this book

Beginning Drupal 8 teaches you how to build, maintain, and manage Drupal 8-based web sites. The book covers what Drupal is, using Drupal when building a new web site, installing and configuring Drupal, creating and managing content, managing users, adding functionality to your web site through Drupal modules, and advanced topics on using themes, panels, and views.

The book also builds practical examples of common Drupal sites, such as a company website, a community website, and a commerce website, that you can take and expand on to create your own Drupal 8 sites. By reading this book, you will understand the power of the Drupal platform, and why you should be using Drupal if you're not already. Through following the samples in the book, you will quickly build your confidence and your ability to use Drupal. Beginning Drupal 8 gives you the knowledge necessary to build, deploy, and manage web sites on Drupal 8.

Table of Contents

Frontmatter
Chapter 1. Introduction to Drupal
Abstract
This chapter provides a basic overview of what a content management system (CMS) is, how Drupal fills the role as a CMS, the major building blocks of Drupal, and how to create content on your new Drupal website.
Todd Tomlinson
Chapter 2. Creating and Managing Content
Abstract
Remember, a website without content is as interesting and informative as a book without words. In this chapter, I focus on Drupal’s content creating, publishing, editing, and management features, providing you with the knowledge necessary to venture out and create, publish, and manage a wide variety of content on your new Drupal website. You started that process in the previous chapter; now let’s see what you can add.
Todd Tomlinson
Chapter 3. Creating and Managing Users
Abstract
Now that your site is up and running, you have a couple of decisions to make. First, will you have any administrators on the site other than yourself? Second, will your site be open to everyone, or will users need to log in to view content and other features? In this chapter, I cover how Drupal treats visitors to your site, and how you as a site administrator can configure Drupal’s user account features to restrict the capabilities of those who have user accounts on your system.
Todd Tomlinson
Chapter 4. Taxonomy
Abstract
One of the Drupal features new Drupal users underuse and misunderstand is taxonomy. New Drupal users are overwhelmed with all of the other features and functions provided by the platform, and they bypass what may be one of the most powerful and useful features that Drupal has to offer. In this chapter you will create and use taxonomy terms to categorize content so that visitors can easily find information related to a specific topic.
Todd Tomlinson
Chapter 5. Content Types
Abstract
If you ask Drupal developers what the most powerful feature of Drupal is, many will say it’s Drupal’s ability to create custom content types. What is a content type? Think of a content type as a template that you provide to users who author content on your site. You may decide that the standard content types that come with Drupal out of the box, “Basic page” and “Article,” provide all the features you need for your site. But it’s likely that you’ll encounter situations where you want more control over how users enter information and how that information is displayed on your site, and that’s where custom content types come into play. In this chapter I’ll show you how simple it is to create a new content type from scratch. Hold on to your tickets, we’re about to take off!
Todd Tomlinson
Chapter 6. Using Drupal Themes
Abstract
In this chapter I will explain the process of changing the overall look and feel of your site by installing a new theme. I will walk you through the process of selecting, downloading, and enabling your selected theme. You’ve added some neat things to your site in previous chapters, and we’ve seen some exciting features of Drupal; but this chapter will have you exclaiming “wow!”
Todd Tomlinson
Chapter 7. Creating Menus
Abstract
A key factor in defining the success or failure of your new website is whether visitors can find information on your website, particularly the information that you want them to find. There are three basic mechanisms in Drupal to provide navigational capabilities to your site:
Todd Tomlinson
Chapter 8. Drupal Blocks
Abstract
In this chapter I focus on using blocks to assign content and what are commonly called “widgets” (which include the user login form, latest blog posts, a list of who is currently logged into your site, the current weather conditions, and the like) to specific positions on a page. I will cover standard blocks that ship with Drupal 8, blocks that come with contributed modules, and information on how to build a custom block from scratch. At the end of the chapter you will have the ability to construct a page with some pretty exciting features.
Todd Tomlinson
Chapter 9. Views
Abstract
If you ask anyone who has used Drupal for a while what the “killer module” is, the answer will likely be Views, Panels, or custom content types. In that list, Views is usually mentioned first, and it’s the module that many users say they can’t live without. What does the Views module do that is so special? Simply stated, Views provides an easy-to-use interface for selecting and displaying lists of content on your website. Examples of how you might use Views include
Todd Tomlinson
Chapter 10. Creating Pages
Abstract
Now that you have a general understanding of content types, blocks, views, and themes, you’re ready to start assembling pages on your website using a combination of each of those elements. A page may represent a single piece of content (for example, a news story about the first day at DrupalCon), or it may represent a landing page similar to the front page of Drupal.org. Each page on your site may vary in structure, thanks to the flexibility of the theme that you select for your site as well as the blocks mechanism and the ability to specify on which page (URL) a block is to be displayed. Using Views to create blocks provides a dynamic mechanism for extracting content along with static blocks created through the blocks interface. The combination of Drupal 8 tools provides a powerful mechanism for creating an awesome site.
Todd Tomlinson
Chapter 11. Drupal Modules
Abstract
Drupal is an amazing product in its off-the-shelf state. The features and functionality provided in Drupal 8 core are often more than adequate to meet the needs of many who build their websites with Drupal. But there are times when you need a feature that isn’t possible with Drupal core alone, and in those cases you need look no further than the thousands of contributed modules that have been written to address just about anything you could think of doing on a Drupal based website.
Todd Tomlinson
Chapter 12. Anatomy of a Module
Abstract
Although it is possible to build relatively complex Drupal 8 sites without ever having to look at the internals of a module, there may be instances where you’ll need to understand some of the inner workings of a module in order to fully take advantage of the features that the module provides. In this chapter I’ll take you on a high-level tour of what constitutes a module in Drupal 8 by walking you through the creation of a simple Drupal 8 module.
Todd Tomlinson
Chapter 13. Multilingual Capabilities
Abstract
We live in a world where cultural and country boundaries, while still important, are blurred by the Internet’s capability to connect two people who are geographically thousands of miles apart and enable them to communicate through text, voice, and video. The visitors who come to our websites may be our next-door neighbors or they may live half a world away. Catering to those who live beyond our region and do not share our native tongue is now more commonplace than ever. Website designers who break through the language barriers on their sites may attract audiences that they never dreamed of having in the past, and Drupal 8 makes that possibility a reality through its built-in multilingual capabilities.
Todd Tomlinson
Chapter 14. Administering Your Drupal Site
Abstract
If you have followed along in the previous chapters, you now have enough knowledge to build a Drupal 8-based website. Building your website and releasing it to the world is an exciting experience, and one that often brings with it great pride and joy. Whether your site has two or three pages or hundreds, deploying a website and seeing traffic on it is a rewarding and enriching experience. Deploying your website is just a step along the journey; it is by no means the end. As the proud owner of a website, you must monitor it, nurture it, expand it, and support it, all of which are involved in administering your website.
Todd Tomlinson
Chapter 15. Using Drush
Abstract
This chapter provides a basic overview of Drush, a command-line tool that greatly simplifies the tasks of building and administering a Drupal 8 website. With Drush, tasks that often require logging onto your site, navigating to a site administration page, and filling out a form can now be performed with a simple command-line interface. Drush also enables you to administer one or several sites remotely, without having to log onto each server and each site to perform routine maintenance tasks. Drush handles most of the tasks associated with managing modules, themes, and user profiles and common administrative tasks like running cron, creating backups, and clearing caches. You can even execute SQL command from Drush.
Todd Tomlinson
Chapter 16. Using Git
Abstract
This chapter provides a basic overview of Git, a source code control system adopted by the Drupal community during the creation of Drupal 7. What is a source code control system, you ask? It is any tool that enables developers to manage changes to documents, source code, and other collections of information. If you have ever made changes to a document or a piece of code and then subsequently wished that you could go back in time and undo those changes, a source code control system would have saved the day. That’s one of the key features of source code control: the ability to take a snapshot of digital assets at a given point in time and then retrieve that snapshot at a later date to restore the previous state.
Todd Tomlinson
Chapter 17. Putting It All Together
Abstract
Reading this book has given you the foundation of knowledge on which to continue to build your Drupal skills. If you are new to the concept of a web content management system, you may not be able to jump in and build a highly complex site as your first endeavor with Drupal. But like all things in life, you have to start somewhere, and you now have the tools and knowledge to begin your journey. For those of you who had previous content management experience, hopefully the book helped to cast a light on how Drupal works so you can correlate what you know from other CMS platforms with what Drupal provides.
Todd Tomlinson
Chapter 18. Creating a Responsive Site
Abstract
Just a few short years ago, smartphones and tablets didn’t exist, yet here we are today living in a world where analysts predict that web traffic from these devices will surpass that of laptops and desktops in 2014. We live in a mobile world, and as Drupal site builders, it’s important to address the growing usage of smartphones and tablets and begin to think about mobile first as we build new sites. If the majority of users visiting our sites are on smaller screens, it would be wise for us to deliver an amazing user experience regardless of the device they are using.
Todd Tomlinson
Chapter 19. Creating a Blog Site
Abstract
Blogs, blogs, and more blogs. As of April 2015 there were approximately 229.7 million blogs on Tumblr, 75.8 million blogs on WordPress, and millions of other blogs on Blogger and other platforms like Drupal. Conservatively, that’s a nearly a third of a billion websites dedicated to blogging, or roughly 33% of all websites on the Internet (currently hovering around 923,000,000 according to www.internetlivestats.com ). When you couple the sheer number of blog sites with the average number of blog posts published per day, 3 million (Technorati), the numbers are staggering. A Drupal site builder could stay very busy just building blog sites!
Todd Tomlinson
Chapter 20. Building a Company Site
Abstract
In a relatively short time span, the Internet has changed everything about the way business is conducted. What was once a novelty, having a website on the Web, has now become essential for all companies large and small, regardless of industry. In the eyes of the customer, a company that doesn’t have a website is often perceived as possibly being illegitimate. Fortunately, Drupal 8 is an excellent platform for quickly and effectively creating an organization’s online presence.
Todd Tomlinson
Chapter 21. Building a Community Site
Abstract
The ability for people to assemble in online communities has exploded over the past several years. There are online communities for nearly everything you can think of—from technology (think Drupal!), sports (e.g., fans of a soccer club), and entertainment (e.g., enthusiasts of a particular music genre), to food, nutrition, boating, flying, hiking, endangered animals, and thousands of other topics for which there are groups of people who gather in a virtual community to share ideas, ask questions, set up events, and connect. There are online communities focused around individual products, groups of products, and companies. There are also online communities sponsored by companies to help guide and direct those who purchase their goods and services. The opportunities are limitless; all it takes is two or more people and an idea to launch an online community.
Todd Tomlinson
Chapter 22. Building a Commerce Site
Abstract
In a relatively short 20 years, the concept of selling goods and services on the Internet has gone from a novelty to the mainstay of business. If you are a business and don’t provide an online channel to sell to your target customers, you are missing out on a tremendous opportunity to increase revenue, market share, and profitability. Drupal Commerce provides a robust and full-featured solution for building online storefronts, and in this chapter I’ll walk you through the process of creating a commerce site. To demonstrate the ease of building a commerce site on Drupal, I’ll create a site that is focused on selling Drupal T-shirts, coffee cups, and hats. The concepts can be expanded on to sell any physical or virtual goods, so you are welcome to either follow along and build the Drupal commerce site or use the example presented as a guide to create your own commerce site.
Todd Tomlinson
Appendix A. Installing Drupal
Abstract
If you are hosting your Drupal site on a commercial web-hosting provider, it is likely that it has a tool that installs Drupal for you. If that’s the case, you can bypass this appendix and follow the directions provided to you by your web-hosting provider. But if you need to install Drupal on your laptop, desktop, or server, then this appendix is for you.
Todd Tomlinson
Appendix B. Additional Resources
Abstract
As you begin (and continue) your journey of learning Drupal, there will likely be times when you’ll need to find a Drupal module, a Drupal theme, additional details about specific Drupal technologies (such as theming), and operating system–level commands (for tasks such as backing up the site from the command line). This appendix points you to recommended websites where you can find additional resources to help you along your journey.
Todd Tomlinson
Backmatter
Metadata
Title
Beginning Drupal 8
Author
Todd Tomlinson
Copyright Year
2015
Publisher
Apress
Electronic ISBN
978-1-4302-6581-8
Print ISBN
978-1-4302-6580-1
DOI
https://doi.org/10.1007/978-1-4302-6581-8

Premium Partner