• Aucun résultat trouvé

Example Build Recipes

Dans le document PART I PLANNING YOUR WEBSITE (Page 20-200)

PART III AN EXAMPLE SITE

CHAPTER 10 Example Build Recipes

The Requirements Inventory 433

Pages 434

Content Types and Fields 439

Taxonomy Vocabularies 442

Blocks 443

The Module Recipe 445

Comparing Drupal Core Modules 446

Site Modules 450

Drupal Distribution 458

The Development Sequence 459

The Environments 460

The Implementation 460

Expert Acquisition 461

Training Plan 461

Marketing Plan 464

The Sustainment 465

Maintenance Tasks 465

Site Management Tasks 465

Summary 467 INDEX 469

ftoc.indd xviii

ftoc.indd xviii 6/20/2011 6:51:43 PM6/20/2011 6:51:43 PM

FOREWORD

This book is about directing diverse forces toward a unifi ed goal: the completion of a web project.

While the goal in this case is very specifi c — a Drupal website — in many ways, it outlines success-ful steps for completing any life project, including Drupal itself.

I started the Drupal project in my dorm room in 2001, with no expectation that it would ever become big outside my circle of friends. But it grew, leaving that circle to power KernelTrap.org (which still runs on Drupal) and then, famously, the website for Howard Dean’s 2004 presidential campaign. Drupal’s gone through three major updates since then, and each time the Drupal commu-nity learns more about how to apply project management techniques to its development.

But, as with many projects, planning for Drupal was often ex post facto. I wrote it for a small, specifi c purpose: when it escaped the confi nes of my expectations, the Drupal community had to refactor it, sometimes ripping out large sections. Partly such changes were necessary because we wanted to take advantage of new web technologies, such as RDF for Drupal 7 and HTML5 for Drupal 8. But, sometimes they were because we didn’t have a systematic method to plan and build.

This book provides that systematic method — but for Drupal websites. Few are the web builders who haven’t created a “quick and dirty” site at some point in their careers, and then regretted it later when they had to make changes. We know why we do it: we’re in a rush and don’t think the project is worth the extra time.

However, once you learn proper planning techniques, you’ll fi nd that they don’t add time to your project, because they reduce the number of revisions and corrections needed later. That’s why I’m excited about this book. It will help people build Drupal websites the right way. And the more Drupal sites that are built well from the beginning, the better people will feel about Drupal overall.

The proof that Ms. McCourt understands her subject is in your hands, for this book is an expres-sion of her ability to direct diverse forces toward a unifi ed goal. I hope that it helps you harness the forces affecting your own Drupal website project, and look forward to seeing the results.

— Dries Buytaert Founder and Project Lead, Drupal (drupal.org) Co-founder and CTO, Acquia (acquia.com)

flast.indd xix

flast.indd xix 6/18/2011 1:18:03 PM6/18/2011 1:18:03 PM

INTRODUCTION

IN JUST MINUTES, you can install a basic Drupal site and start adding content. In a few more min-utes, you can have a new feature at your fi ngertips, ready to use, by installing one or more of the many modules that come with Drupal or any of the thousands of modules contributed by the Drupal community.

With so many modules to choose from, it is sometimes hard to know which modules are the right ones and how to best confi gure them to achieve your goals. This is where planning helps. In a nut-shell, you identify what your site needs to do, decide what it should look like, and identify who will use it. With that information in hand, you can decide which Drupal installation and modules will give you the site of your dreams.

Sounds simple, and in some cases it is. You can plan a site, its development, and its future growth on a napkin over drinks. But most the time, it will take a little more planning to leverage the power and fl exibility of the Drupal framework.

If you have never worked with Drupal before, you might be wondering how you can plan a site built with Drupal. One option would be to work side-by-side with web designers and developers who have experience with Drupal. But if you don’t have access to those who can help, that’s okay. This book provides a series of analyses and tasks that will enable you to start thinking in Drupal and help you plan each phase of your site’s lifecycle.

I hope you fi nd this book helpful as you venture forward on your next Drupal project.

WHO THIS BOOK IS FOR

If you are involved in or responsible for collecting requirements, creating a design plan, planning development, coordinating implementation, and/or sustaining a site built with Drupal, this book is for you. You could be a site owner, project manager, requirements analyst, interface designer, and/or site developer. Note that the book is not intended for those looking for detailed instructions on how to install and confi gure Drupal.

WHAT THIS BOOK COVERS

The analyses and tasks provided in this book are not specifi c to Drupal, but they are presented from a Drupal perspective. The Drupal-specifi c notes provided throughout the chapters speak to Drupal 6 and Drupal 7, providing you with development insights as you move through the planning process.

Chapter 9 plans a Drupal site and Chapter 10 offers a Drupal 6 and Drupal 7 module solution.

flast.indd xxi

flast.indd xxi 6/18/2011 1:18:04 PM6/18/2011 1:18:04 PM

xxii

HOW THIS BOOK IS STRUCTURED

The order of the chapters refl ects a site’s lifecycle and the waterfall development methodology.

However, the sequence of the chapters is not necessarily intended to promote the waterfall meth-odology. Analyses and tasks provided in the chapters can be performed in an order suitable to your project. If this is your fi rst exposure to development, consider walking through the chapters in order so that you can make an informed decision about whether you want to adjust the sequencing on your own project.

Part I: Planning Your Website

Chapter 1, “Introduction to Drupal and Planning,” provides a quick introduction to Drupal, an overview of a site’s lifecycle, and where planning fi ts in.

Chapter 2, “Managing Open Source Projects,” provides insights into various development methodologies and management practices you might fi nd useful on a Drupal project.

Chapter 3, “Conducting a Needs Analysis,” goes beyond asking the question “Do I need a site?” and identifi es the purpose of your site and how your competitors might infl uence how you proceed.

Chapter 4, “Collecting Requirements,” offers a series of analyses designed to facilitate the identifi cation and analysis of what your site needs to meet its purpose.

Chapter 5, “Creating a Design Plan” provides a process for translating your requirements into a visual representation of your site.

Part II: Building and Sustaining Your Website

Chapter 6, “Planning Development,” offers a process to identify a development solution that meets your specifi c requirements and design.

Chapter 7, “Coordinating Implementation,” covers site launch and more. It covers many of the non-development tasks that should be considered for a successful site launch.

Chapter 8, “Sustaining the Site” explores both routine and planned maintenance for your Drupal site, as well as site-management tasks that support your site’s users.

Part III: An Example Site

Chapter 9, “An Example Plan,” puts into practice the analyses and tasks presented in Chapters 3 through 5.

Chapter 10, “Example Build Recipes,” creates a development plan and Drupal 6 and Drupal 7 module recipe that can be used to build the site defi ned in Chapter 9. It also describes how the site will be implemented and sustained.

flast.indd xxii

flast.indd xxii 6/18/2011 1:18:04 PM6/18/2011 1:18:04 PM

xxiii INTRODUCTION

WHAT YOU NEED TO USE THIS BOOK

There are references to Drupal settings, modules, and resources in notes throughout the book, so access to the Internet and a Drupal installation, while not required, might be useful. Analyses and tasks discussed in the book can be performed with pencil and paper, on a whiteboard, using vari-ous applications like Microsoft Word or Excel, or a with simple drawing tool. If you opt to perform these analyses and tasks, choose a strategy that works for you.

CONVENTIONS

To help you get the most from the text and keep track of what’s happening, we’ve used a number of conventions throughout the book.

The pencil icon indicates notes, tips, hints, tricks, and asides to the current discussion.

As for styles in the text:

Wehighlight new terms and important words when we introduce them.

We show keyboard strokes like this: Ctrl+A.

We show fi le names, URLs, and code within the text like so: persistence.properties.

We present code in two different ways:

We use a monofont type with no highlighting for most code examples.

We use bold to emphasize code that is particularly important in the present context or to show changes from a previous code snippet.

ERRATA

We make every effort to ensure that there are no errors in the text or in the code. However, no one is perfect, and mistakes do occur. If you fi nd an error in one of our books, like a spelling mistake or faulty piece of code, we would be very grateful for your feedback. By sending in errata, you may save another reader hours of frustration, and at the same time, you will be helping us provide even higher-quality information.

To fi nd the errata page for this book, go to www.wrox.com and locate the title using the Search box or one of the title lists. Then, on the book details page, click the Book Errata link. On this page, you

flast.indd xxiii

flast.indd xxiii 6/18/2011 1:18:04 PM6/18/2011 1:18:04 PM

xxiv

can view all errata that have been submitted for this book and posted by Wrox editors. A complete book list, including links to each book’s errata, is also available at www.wrox.com/misc-pages/

booklist.shtml.

If you don’t spot “your” error on the Book Errata page, go to www.wrox.com/contact/techsupport .shtml and complete the form there to send us the error you have found. We’ll check the informa-tion and, if appropriate, post a message to the Book Errata page and fi x the problem in subsequent editions of the book.

P2P.WROX.COM

For author and peer discussion, join the P2P forums at p2p.wrox.com. The forums are a web-based system for you to post messages relating to Wrox books and related technologies and interact with other readers and technology users. The forums offer a subscription feature to email you topics of interest of your choosing when new posts are made to the forums. Wrox authors, editors, other industry experts, and your fellow readers are present on these forums.

At p2p.wrox.com, you will fi nd a number of different forums that will help you, not only as you read this book, but also as you develop your own applications. To join the forums, just follow these steps:

1.

Go to p2p.wrox.com and click the Register link.

2.

Read the terms of use and click Agree.

3.

Complete the required information to join, as well as any optional information you wish to provide, and click Submit.

4.

You will receive an email with information describing how to verify your account and complete the joining process.

You can read messages in the forums without joining P2P, but in order to post your own messages, you must join.

Once you join, you can post new messages and respond to messages other users post. You can read messages at any time on the Web. If you would like to have new messages from a particular forum emailed to you, click the Subscribe to this Forum icon by the forum name in the forum listing.

For more information about how to use the Wrox P2P, be sure to read the P2P FAQs for answers to questions about how the forum software works, as well as many common questions specifi c to P2P and Wrox books. To read the FAQs, click the FAQ link on any P2P page.

flast.indd xxiv

flast.indd xxiv 6/18/2011 1:18:09 PM6/18/2011 1:18:09 PM

PART I

Planning Your Website

CHAPTER 1:

Introduction to Drupal Planning

CHAPTER 2:

Managing Open Source Projects

CHAPTER 3:

Conducting a Needs Analysis

CHAPTER 4:

Collecting Requirements

CHAPTER 5:

Creating a Design Plan

c01.indd 1

c01.indd 1 6/18/2011 1:18:41 PM6/18/2011 1:18:41 PM

1

Introduction to Drupal Planning

The task of planning websites has fallen on the shoulders of project managers, graphic designers, software developers, requirements analysts, web strategists, user experience experts, and information architects, to name a few. All these roles have their own perspec-tives of how a site should look and come together. Their individual experiences and skills associated with planning sites infl uence what is included in the site, how it is built, and how it is maintained. Their planning processes will emphasize their strengths, and typically, there isn’t anything wrong with that.

Unless the individuals fi lling these roles have some insight into what Drupal has to offer and how it gets the job done, the site plan could miss some features that could make the site even better than originally thought. It could also set expectations that Drupal does not support at the moment. With some insight into Drupal and how it works, any of the people in these roles can plan a Drupal site.

By the end of this book, you will have methods, tools, and techniques that can help you plan Drupal sites. By the end of this chapter, you should be able to recognize:

The basics of how Drupal works

Some basic Drupal-related terms

How Drupal sites are different from HTML sites

Phases of a Drupal site’s lifecycle

EXPLORING DRUPAL

You likely know what Drupal is, but in case you do not, it is an open source content manage-ment system (CMS). It is used to build:

Dynamically generated websites

Web applications

c01.indd 3

c01.indd 3 6/18/2011 1:18:46 PM6/18/2011 1:18:46 PM

Document repositories

E-commerce sites

Learning sites

And more

To plan a Drupal site, knowing a little about how Drupal works can help. Don’t worry; you don’t have to be a developer to understand some of the basics. The following is offered as insight and to help the team communicate. If you are going to be a builder, developer, or themer, this short intro-duction is a must-read.

THEMER

Athemer is someone who develops the PHP, HTML, and CSS that defi ne the page structure and appearance.

Drupal Components

You do not need to know how to build the site in order to plan what you want, but the more you know about what Drupal can do and how it does it, the better off you will be. Let’s start by taking a high-level view of what makes up Drupal.

Drupal’s insides can be broken into the following three categories:

Data storage

Modules (and all the other important code that makes Drupal run)

Theme code

Data Storage

The content of your site and its confi guration settings are stored in a database. By default, each website has its own database. You can confi gure multiple sites to share a database as well. So, if you are planning multiple sites that need to share the same data, this is possible.

On the topic of multiple sites sharing, you should also know that you can have multiple sites, each with its own database, sharing the same Drupal installation. For example, assume you provide Drupal train-ing and host the traintrain-ing sites. You can run all the traintrain-ing sites from one installation of Drupal. Each training site would have its own database, but they would share the code that is Drupal.

Data in the database is only part of your storage needs. If you have any media fi les or documents that you want to upload to the site, Drupal stores those fi les, by default, in a directory on the server associated with the site. If you have sites sharing the Drupal installation, the fi les will be kept sepa-rate from each other unless the sites have been confi gured to do otherwise. The setting that tells Drupal where to save fi les is stored in the database for that site. This means a series of sites using the same installation of Drupal won’t get their media and documents mixed up.

c01.indd 4

c01.indd 4 6/18/2011 1:18:50 PM6/18/2011 1:18:50 PM

Exploring Drupal x 5

PUBLIC OR PRIVATE FILES

In Drupal 6, you have the option of making all your fi les either public or private.

Drupal 7 provides support for both public and private fi les.

Modules

If you have talked to anyone about Drupal, you probably heard him or her say something like,

“There is a module that will do that.”

Drupal is made up of a series of scripts that work together to produce the features you see in your site via a browser. The most common scripts are referred to as modules. Modules are bundles of code that enable Drupal, you, and/or your site visitors to see or do something in your Drupal site.

Drupal modules can be categorized. Here are four categories often referred to in the Drupal community:

Core — Core modules are required for Drupal to work. You can see these modules in the administrative module list, but you cannot disable them.

Core optional — Optional modules provide functionality that you can add to your site. Some of the most commonly used modules will already be enabled for you by default, although you can disable them if you do not need them. Each new version of Drupal refi nes the number of core modules, making the enabling of commonly used features easier.

Contributed — Contributed modules are pieces of code that you can add to enhance the functionality of your site. Contributed modules are developed and maintained by members of the community. Some contributed modules are now part of the core.

Custom — Custom modules are pieces of code that you create to provide specifi c function-ality for your site. Custom modules are maintained by you. You can contribute custom modules to the community, but unless someone wants to maintain the contribution for you, you will be responsible for its maintenance and support.

If you have a particular feature you want to include in your plan, searching Drupal.org for exist-ing modules that might support that feature is sometimes helpful. Plannexist-ing a feature whose module does not yet exist could impact how the site is developed, when it will be fi nished, and the skills you need on board to actually implement the site.

CORE MODULE ADDITIONS

Each time Drupal advances to another version, it increases (and sometimes

decreases) the number of core modules. Drupal 7 is no exception. The most notable addition to Drupal 7 is the ability to add fi elds to content forms. This is supported in Drupal 5 and 6 by the Content Construction Kit (CCK) module. Now, CCK is part of Drupal 7. According to Drupal.org, more than 60 contributed modules were integrated into Drupal 7.

c01.indd 5

c01.indd 5

Dans le document PART I PLANNING YOUR WEBSITE (Page 20-200)

Documents relatifs