Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Drupal 8 Configuration Management

You're reading from   Drupal 8 Configuration Management

Arrow left icon
Product type Paperback
Published in Mar 2015
Publisher
ISBN-13 9781783985203
Length 148 pages
Edition 1st Edition
Languages
Tools
Concepts
Arrow right icon
Toc

Table of Contents (11) Chapters Close

Preface 1. Understanding Configuration Management 2. Configuration Management for Administrators FREE CHAPTER 3. Drupal 8's Take on Configuration Management 4. The Configuration Management API 5. The Anatomy of Schema Files 6. Adding Configuration Management to Your Module 7. Upgrading Your Drupal 7 Variables to the Drupal 8 Configuration 8. Managing Configuration for Multilingual Websites 9. Useful Tools and Getting Help Index

Upgrading your variables


When upgrading your variables from Drupal 7 to Drupal 8, you first need to identify whether the variables are a simple configuration (for example, the number of nodes displayed to a user) or whether you need to create a more complex configuration object (for example, an image style). Some variables, though, are not meant to be permanent (for example, the time of the last Cron run); additionally, therefore, you will have to decide if it should be a configuration (which is permanent by definition) or a state (which reflects information about the current site's state, but we will come back to this later).

Simple configuration

Let's start with a simple example and a simple variable to convert. Simple variables are, for example, the number of nodes on the front page, the name of your site, or whether your site is in maintenance mode.

We assume that our module built for Drupal 7 uses variables to store settings that a user might configure. So, the module provides a small...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image