Follow Slashdot stories on Twitter

 



Forgot your password?
typodupeerror
×
Image

Book Review: Definitive Guide To Drupal 7 55

Michael J. Ross writes "Most computer and web programming books are written entirely by a single author, while the remaining are written by more authors, typically with each one tackling several chapters. The latter approach can suffer from redundant material undetected by editors, and inconsistency in the writing style from one chapter to the next. Yet it offers the significant advantage that the subject matter of each chapter can be presented by an authority on that topic — who can focus on making that explication the best possible, without the burden of completing an entire book. That was one of my first thoughts (and hopes) when hefting the 1112 pages and 4.1 pounds of the Definitive Guide to Drupal 7." Read on for the rest of Michael's review.
Definitive Guide to Drupal 7
author A cast of thousands.
pages 1112 pages
publisher Apress
rating 8/10
reviewer Michael J. Ross
ISBN 978-1430231356
summary A wide-ranging exploration of the latest version of Drupal.
This tome was published on 19 July 2011, under the ISBN 978-1430231356, by Apress (who kindly provided a review copy). As of this writing, it appears to be the longest Drupal book in existence — more than 400 pages longer than the nearest two contenders. Fortunately, no single author ended up in an insane asylum as a consequence of trying to write such an extensive work on his own. Rather, this book is largely due to the efforts of 34 writers in total — more specifically, 30 authors (listed on the front cover, roughly in descending order of how many of the pages they wrote) and four more contributors (added to the list on the title page). This may be a new record in technical book publishing. The entire authorial crew won't be listed here, but it should be mentioned that Benjamin Melançon was the lead author, and contributed to many of the chapters.

The book's material is organized into 38 chapters and nine appendices — all grouped into eight parts: Getting Started, Site Building Foundations, Making Your Life Easier, Front-End Development, Back-End Development, Advanced Site-Building Topics, Drupal Community, and Appendix. The chapter and appendix titles won't be listed here, but can be found on the publisher's book page, which also offers a description of the book, a section for reported errata (none as of this writing), links to purchase the print and electronic versions of the book, and a downloadable archive of the source code. Unfortunately, the code is apparently available only as a Git repository, and thus is inaccessible if you cannot — or do not want to — install Git on your computer. Consequently, it would be more difficult for such a reader to follow along and implement the example code while reading the book.

The authors have created their own website for the book, where visitors can sign up for e-mail notification of updates and free chapters, view a chapter outline (which features some bonus material), see author photos and bios, offer suggested changes for future editions, and learn of reported errata (three, at this time). Throughout the book, readers are told to access that site for additional information related to the chapters' topics; yet there does not appear to be any such information, even after registering a new account and logging in. This will be most disappointing in those cases where the reader is enticed by the promise of valuable information, only to find that it is absent. The authors state (page lv) that there are forums, one per chapter; but those do not yet exist. In general, there seems to be a huge disconnect between that website and the claims made in the book as to what extra material readers will find there.

The book begins with some introductory material, consisting of three mini-chapters: "What's New in Drupal 7" briefly describes some of the terrific improvements over version 6. "How to Use the Book" reassures the prospective reader that the book "does not presume any specific prior curriculum", although this seems inconsistent with the back cover's user level of "Intermediate-Advanced". Also, readers may be perplexed by the claim that the URL path admin/people/permissions/rules will go to admin/help (page lv). The last section, "How Drupal Works", oddly does not explain how Drupal works, but instead discusses some common terms and the typical phases of a website development project.

The first part of the book comprises two chapters, the first of which has the promising title of "Building a Drupal 7 Site", and provides a cursory summary of site planning, wireframing, Drupal installation, the Administration menu, the Shortcut toolbar, color schemes, and modules. The chapter continues with sections on content types, blocks, taxonomy, and other key concepts — all grouped under the chapter head "Allowing People to Register and Log in with OpenID", even though those topics are unrelated to OpenID. All of the chapter's topics are illustrated by stepping the reader through building, from scratch, the beginnings of the Drupal 7 website — namely, one similar to the authors' site mentioned earlier. Unfortunately, some of the instruction in the book does not match the actual website design, e.g., no introductory text (page 20). Readers may be amused by the tip on page 11, which refers to "the remaining 800 pages of the book". Perhaps the remaining 1101 pages can be chalked up to scope creep! The second chapter explains the basics of how to install and use Drush and Git, but not for Windows users. Readers should find the material instructive and consistent, except for the claim that Git is "easy(ish)" even though "getting the hang of Git [is] a lifelong learning process".

The half dozen chapters that compose Part II first introduce some of the most commonly-used Drupal modules, with extensive coverage of Views and later Organic Groups. A couple chapters explain how to keep one's site secure, partly by updating Drupal core and modules. The last chapter continues the development of the example site, using modules presented earlier. All of these chapters' narrative is valuable, although a couple pronouncements are too severe (e.g., "User input is evil", on page 127); but overall the advice is well warranted. Yet the chapter that will most likely aggravate readers is the eighth one. It seems to presume that the reader's test site was not affected by the exercises of the previous chapters, such as the Organic Groups. Secondly, some key information is incorrect, e.g., "Content: Image" (page 159) should be "Content: Headshot". Lastly, the authors refer to items not yet created as though they were, e.g., a "Table of Contents" menu link, an "Outline of Chapters" menu, and a "Twitter" field (pages 162-164). Unfortunately, the effects of all these problems compound, and, combined with the changes in Views since Drupal 7.0, make it increasingly difficult to follow along and implement the instructions.

Part III offers another half dozen chapters, in this case devoted to higher-level, less technical matters — specifically, how to: best participate in the Drupal community, plan and manage a Drupal-based project, craft effective documentation for your sites' end users and support staff, set up a workable Drupal development environment, launch and back up a new website, and stay sane while doing all of this. The information presented is worthwhile, with only a couple peculiarities: Firstly, why is the book organized so that some technical information is presented in the early chapters, as well as later chapters, while a group of "softer" topics are sandwiched in between? Secondly, for Chapter 12, why is the reader told, halfway through the chapter, that she will need "A computer able to connect to the Internet" and "An Internet connection" (page 233)? No one who has worked through the preceding dozen chapters needs to be reminded of this. Perhaps this chapter, on how to set up a development environment, should be made an appendix, as was the other installation and setup topics (Appendices F-I).

The next few chapters, Part IV, explore front-end development — namely, theming and jQuery. The first two chapters were penned by Jacine Luisi, who heads up the HTML5 initiative for Drupal 8. Readers learn about Drupal's core themes, theme engines, theme administration, metadata files, regions, layout, template files, global template variables, theme functions and hooks, preprocess and process functions, render arrays, theming forms, and more. The discussion is competent and thorough, as well as comprehensible, aside from the repeated use of the verb "print" to apparently mean "display". Chapter 17 demonstrates the use of JavaScript and jQuery in Drupal, and finishes by showing how to use jQuery UI to implement animations, such as accordions and progress bars.

Part V, "Back-End Development", comprises seven chapters that explain how to develop custom Drupal modules using the APIs. Because they provide an introduction to Drupal's system of hooks and overrides, they probably should have been located before the earlier chapters on theming, which rely upon those features of Drupal. Regardless, Chapters 18-20, by Benjamin Melançon, attempt to demystify the key topics in module development. Because this subject area is so critical to real-world Drupal development, and because the concepts can be quite intimidating to neophytes, any presentation of it must proceed at a reasonable pace, with clear explanation of how each aspect relates to the next. Like similar discussions in other Drupal books, this one begins quite approachable, but becomes more daunting, with a few places where readers will likely be perplexed — such as the hook_form_alter() discussion (page 411), which doesn't seem to match the resultant HTML. Yet this is such a challenging subject area that entire books have been devoted to it, and this one ventures into areas untouched by other books, such as how to create new database tables. Drupal coding standards are presented, although apparently not always followed in the example code (e.g., preceding internal function names with underscores). Part V is rounded out with chapters on porting modules to Drupal 7, writing "glue" modules, performing functional testing, and writing extendable/API modules.

Part VI, "Advanced Site-Building Topics", consists of ten chapters covering a variety of topics: building an online store using Commerce module (authored by the project's founder and lead, Ryan Szrama); Drush (which overlaps with Chapter 2); caching and storage mechanisms (MySQL and MongoDB); RDFa and the Semantic Web; Drupal's routing system; Drupal's internal operations for presenting a requested page; Solr module; UX enhancements in Drupal 7; completing the book's website; and Drupal distributions. All of the information and guidance appears correct, except for a couple problems: The instructions (page 568) to install Commerce Physical Product module, which does not have a Drupal 7 release, as of this writing, and certainly as of the book's publication date. Drune is a music player used as an example throughout Chapter 34, but its website, drune.org (pages 805 and 817), appears to be dead at this time.

Throughout this book, one will find a strong sense of community, with frequent encouragement for the reader to participate and contribute. This is evidenced by Part VII, which comprises four chapters that present: Drupal's history, how to make a living as a Drupal developer, how to maintain a contributed project, and further thoughts on how to contribute to the overall Drupal community. The book concludes with Part VIII, consisting of nine appendices, most of which focus on how to install Drupal on various platforms. This part is strangely titled "Appendix", yet contains multiple appendices (more scope creep?).

Given the somewhat stunning length of this book, its multitude of authors, and its wide coverage of most aspects of Drupal, it should be expected that the book has both strengths and weaknesses. Consider first that latter category. The authors and publisher should have sought ways to reduce the length of the book. For instance, the overview of PHP in Chapter 18 is not needed for this book's audience, and could be replaced by references to outside, more-detailed resources. The same is true of the section on Drupal coding standards. The book does not need to be made any longer than it already is, without good reason. Speaking of which, most of the longer chapters end with summaries, which are not worth the extra space taken up. Drupal's hook system is explained in at least three different chapters, and Git in two. The many authors should have been aware of this, had they been referencing the book's website, which was presumably built before the text describing it was written. Furthermore, the publisher and its chosen technical reviewers should have also spotted this.

The remarkably large number of authors is probably the primary reason for the book's noticeable unevenness, from one chapter to the next, in the quality of the writing — including the clarity of the explanations, which is arguably the most important factor. In a book written by advanced Drupal developers, it is to be expected that they will use Drupal-specific terminology. That is fine, but such terms should be defined at least once, before encountered by any readers unfamiliar with them. For instance, page xxxv alone mentions "d.o", "D8", and "contrib" — all meaningless to someone learning Drupal. There are places in the text where the descriptions do not match the corresponding screenshots (e.g., the "Required field" on page 18), and where, in the narrative, the lack of quotation marks around field labels makes it jarring and difficult to understand (e.g., throughout Chapter 8). There are some inconsistencies in spelling (e.g., "web site" and "website", even in the same sentence, on page lii), some inconsistencies in italicizing menu links (e.g., page 13), some misused phrases (e.g., "cannot be understated", on pages lix and 225, when "cannot be overstated" was called for), some baffling allusions (e.g., "aiee-the-alligator-is-going-to-get-me", on page 492), curly quotes in the code (e.g., pages 277 and 356-9), a repeated paragraph (page 507), an oxymoron ("libertarian communism"; xlvi), and the obligatory conflation of "depreciated" and "deprecated" (page 495) found in countless programming books.

This book contains numerous errata: "co-maintainer [f]or Drupal 7" (page xxxiv), "and." (xxxv), "bi-lingual" (xxxviii), "able [to] handle" (xlix), "don' think" (lv), "criteria[:] type" (lviii), "able [to] fill" (11), "th[r]ough the" (14), "an a" (19), "ask question questions" (29), "install [the] X-ray" (38), "You [] requests nuggets" (49), "you want to you" (56), "on [the] system" (57), "menu of option[s]" (57), "Rather [than] saving" (57), "menu(" (58), "you[r] Views" (59), "These setting[s]" (61), "that what" (66; should read "than what"), "might for use" (67), "you would chose" (67), "the next sort criteria" (67; should read "the next sort criterion"), "by click[ing]" (74), "you are make" (85), and "have [to] click" (85). At this point, not even 8% of the way in, I stopped recording them — although an amusing one is worth mentioning: "gather shook information" (452). Lastly, how did "Drurpal.org" (854) make it past the spelling check? It turns out that the entire book is peppered with such errors, and that first batch was merely the beginning. It is difficult to believe that so many obvious errata could have made it through any professional copy editing process.

Readers who are following along, and likely using the latest version of Drupal (7.8 as of this writing), will notice some differences between what they see on their screens and what is shown in the book's screenshots — most if not all of which are based upon Drupal 7.0. This is especially noticeable in Chapter 3, which covers Views, a module affected by ongoing enhancement. For instance, Views exporter submodule (page 52) is now gone; "Access all views" (page 53) has been altered; "Display Status" (page 62) is gone; there are no broken link icons to indicate overrides; "views/edit" (in the URL, page 71) is now "views/view"; and the Fields configuration dialog (page 75) is different. Fortunately, none of these cases of obsolescence should have any impact on the value of the information as a whole.

On the positive side of the ledger, this book offers much to be commended. As with any worthwhile programming book, this one makes extensive use of code snippets and screenshots to illustrate concepts discussed. These appear to be correct, except in the flowchart of Figure 30-3, where the conditional symbol's arrows are missing values. The text contains some welcome humor (e.g., a kittens photo request, on page 43) and some apt phrases (e.g., Permission module's "wall of checkboxes", on page 156). Some of the chapters were written by the contrib module developers/maintainers, i.e., those who arguably know those modules best. This is unique among the growing list of Drupal books, in that it devotes entire chapters to topics neglected by its competitors — such as documentation, installation profiles, module porting, Drush, Git, and working profitably as a Drupal professional. Some of this information emphasizes the value of project management (both for your individual projects, and Drupal as a whole).

On balance, the pluses outweigh the minuses. The book has a lot of good information, and many of the problems stem from sloppy writing that should have been caught by the publisher's editing team. It may not be the best source for some key subject areas, such as security or site building options. But if you seek a sole source that offers more information in total, then this is your book. For some topics — such as upgrading Drupal, crafting and testing modules, building installation profiles, and the inner secrets of the menu system — it goes into far more detail than any other. Definitive Guide to Drupal 7 is an impressive attempt to be just that, and no other single book currently matches it.

Michael J. Ross is a freelance web developer and writer.

You can purchase Definitive Guide to Drupal 7 from amazon.com. Slashdot welcomes readers' book reviews -- to see your own review here, read the book review guidelines, then visit the submission page.

*

This discussion has been archived. No new comments can be posted.

Book Review: Definitive Guide To Drupal 7

Comments Filter:
  • drupal drupal drupal. gets pushed like there is no tomorrow despite there are a lot of other good open source cmses, even one which nasa uses.
    • Hmmmm, complaining that an open source project gets mentioned on Slashdot? Maybe the problem people have with Drupal is not realising that it's not just a CMS. I'm currently sitting in my kitchen building an e-commerce site without having to do any coding and the benefit over other e-commerce solutions is that to add a blog, forum or a host of other features only requires a few clicks. I like it.
      • every month a drupal article gets pushed. sometimes it may go up to twice or more a month. you rarely see other cmses pushed like this here.
        • we used to have a grip of articles about wordpress but now that's old. Drupal's not new any more, it's now usable. I got on it in Drupal 4 and I still think it was the best thing then, but it didn't really get great until 6, and even then not until halfway through. I'm still on 6 and probably will be until 8 comes out :p

    • by Eil ( 82413 )

      Drupal isn't a CMS, it's a framework for building one without having to do (much || any) programming.

      • Drupal isn't a CMS, it's a framework for building one without having to do (much || any) programming.

        That is a load of dingo's kidneys. Turning on modules does not count as building a CMS, and that's all you have to do to support additional types of media, relationships between data, new views on data, et cetera. Drupal is nothing if not a framework, it is there to hang modules on, but it is also nothing if not a CMS, which is what it is out of the box. Admittedly, it won't handle many types of content that way, but click click click and there's some more.

        • by AvitarX ( 172628 )

          CCK and Views gives it A LOT of flexibility one does not have in other CMS's.

          You can make a content type of "photos", with a field for an image, caption,some tagging, etc.

          And then in one area display links to galleries based on various fields put in. You can insert it into an article with a caption.

          The ability to make an item contain all relevant info about itself, and display only the parts you want in various contexts is quite powerful.

          If I was making a simple site with blog I would use Wordpress, but the

          • You forgot taxonomies, which is easy to do because they come with drupal — but then, so does a light version of C
            CK. I use some custom vocabularies, CCK and views to display my drinking games archive. It started life as a static page that I manually regenerated with a shell script. Then it was, for a very short time, a CGI shell script. Then it became a CGI Perl script (not using any libraries, because you don't need any) which read a CSV file and a bunch of flat files. Then it became two PHP scripts

    • You should write up a review of grigriphp. While limited (filtering everything through filter_vars) and some general poor coding on the sql bits (you should use parameters and not string your sql together), it looks nice and lightweight.

  • by Ice Station Zebra ( 18124 ) on Wednesday October 05, 2011 @04:47PM (#37618160) Homepage Journal

    Drupal is great software and keeps getting better. If you are going to post that it sucks, please post a link to software you have written so we can compare.

    • Nazism was powerful and kept getting more powerful. if you're going to post that it sucks, please post a link to a regime you have built so we can compare.

    • I guess one reason is there aren't many posts for "Latest book about (WordPress|Joomla|ExpressionEngine|SilverStripe|Concrete5|Plone|etc)" here. And while Drupal is arguably the most interesting of those open-source CMS's from a developer standpoint, it's still the CMS which is "pushed" much more frequently than others here (or that's my impression at least), and... it's a CMS. Aren't those only for dummy non-developers?

      But Drupal is the most open, collaborative, and developer-driven CMS/CMF I know of, so i

    • by blair1q ( 305137 )

      I wasn't going to post that Drupal sucks.

      I'm going to post that, despite a decade of Drupal book reviews being posted almost biweekly on /., I still have no earthly clue what Drupal does, how it fits into the web infrastructure, or why so many people should desire to give enough of a crap to write 2,000-word reviews that are basically expanded listings of the book's contents with a few naff comments thrown in.

      • by Eil ( 82413 )

        I'm going to post that, despite a decade of Drupal book reviews being posted almost biweekly on /., I still have no earthly clue what Drupal does, how it fits into the web infrastructure,

        Yeah, no kiddin' and what's with all these danged Linux stories lately? I tell you what, all I can figure out is that it's some kind of Windows program that kids use to play text adventure games on.

    • If you are going to post that it sucks, please post a link to software you have written so we can compare.

      In the words of Samuel Johnson "You may abuse a tragedy, though you cannot write one. You may scold a carpenter who has made you a bad table, though you cannot make a table. It is not your trade to make tables."

    • I've been building multilingual brochure-type websites in Drupal since 4.7.

      Drupal 7 delivers too little (DBTNG, fields, imagecache in core), too late.

      The new admin overlay is so bugged that it's practically unusable, even with the (default) Bartik theme.

      Worst part of it for me is there are major regressions, especially related to i18n functionality, and the "i18n" module doesn't help as it did in earlier versions of Drupal anymore.

      There are opened bugs for the above, many of which were opened even before D7

  • by Hazel Bergeron ( 2015538 ) on Wednesday October 05, 2011 @04:49PM (#37618188) Journal

    Modern software development is so boring. Most developers waste so much time learning some new hep framework which will become irrelevant in a couple of years and spend no time actually thinking about how to solve interesting problems.

    Slowly but surely we're the approaching asynchronous functional multiprogramming which first became the subject of research, well, 40 years or so ago. In the meanwhile, we'll have to put up with this fly-by-night BUY MY STUFF THEN MENTION IT ON YOUR CV crap.

    • ^ Irrelevant tangent. Web developers most frequently need to deliver flexible, stable, usable systems for non-developers to interact with. That's where CMS's come in. The utility of asynchronous functional multiprogramming is...debatable in such a scenario.

      Drupal is totally open-source (with an extremely active and involved community) and almost entirely developer-driven, so there is no "buying", other than the kool-aid :). It also appears to be on a steady growth curve, picking up both more sites and bigge

  • and one book closer to the cookie jar.

  • by Anomalyst ( 742352 ) on Wednesday October 05, 2011 @05:12PM (#37618484)
    Print Book Price: $49.99
    eBook Price: $34.99
    • On Amazon the paper price and the Kindle price are about the same... ~$25 i think it is a dollar more for the privilege of not carrying 4.2 pounds around!

  • by peter hoffman ( 2017 ) on Wednesday October 05, 2011 @05:14PM (#37618498) Homepage

    I have the book and I initially bought the electronic copy through Amazon to read using Kindle software on my PC and Droid X.

    Even on a 1920x1080 21" display, I found some of the diagrams to be illegible. In particular, figure 15-14 was completely unusable.

    As a result, I returned the electronic version and bought the paper version from my local Barnes & Noble. I then bought a PDF copy from Apress.com for $10 more since I registered my copy with them.

    I have found the book to be pretty good but landing more in the reference camp than the tutorial camp. I need the reference so I'm glad to have the book but I need a good tutorial on creating themes for Drupal 7 and I'm still looking.

  • Just like Drupal (Score:4, Insightful)

    by Curunir_wolf ( 588405 ) on Wednesday October 05, 2011 @05:19PM (#37618560) Homepage Journal

    The remarkably large number of authors is probably the primary reason for the book's noticeable unevenness, ... in the quality of the writing ... terms should be defined at least once, before encountered ... There are places ... where the descriptions do not match the corresponding screenshots ... and where the lack of [marks] makes it jarring and difficult to understand. There are some inconsistencies in spelling ... even in the same sentence, some inconsistencies in [formatting], some misused phrases, some baffling allusions, curly quotes in the code, a repeated paragraph, an oxymoron ("libertarian communism"), and the obligatory conflation of "depreciated" and "deprecated".

    Sounds like the book was developed and organized exactly the way Drupal is!

  • I've tried to get started building a Drupal site a couple of times, first with 6, then with 7. Both times, I found the available books already hopelessly out of date and the on-line tutorials less than enlightening. I'm no technical slouch but I don't have gobs of free time, either. Can anyone recommend some good references that a Drupal novice can use to get a halfway decent looking, functional site going? I'd like to develop a simple custom theme so that site doesn't look obviously copied from some st

  • Wait, a Slashdot book review of a book not published by Packt Publishing?

    I didn't think that was possible. By the same reviewer [slashdot.org] no less!

  • The book has a mere 1112 pages, and a quick check at amazon.com shows that the "typical pages" have the usual margins, plus lots of the white space that techie book designers love these days.

    So there's no way it can be "definitive". Or "complete". For something as massively "featureful" as drupal, it can barely qualify as informative.

    So c'mon; pull the other one ...

  • 1112 pages about web technologoy printed on paper? What a curious idea. How does the search engine work?

  • by cornface ( 900179 ) on Wednesday October 05, 2011 @10:19PM (#37621876)

    Another long winded and hard to read review for Drupal that alternates between explaining the table of contents and talking about how terrible the book is.

    8/10

  • I don't understand why anyone would write a book that would be guaranteed to have outdated information almost immediately.
    • This book focuses on long-lived fundamentals; on helping readers learn how to think about solving problems and taking on new challenges; and on tools that don't change with the Drupal version.

      That said, the book is not already outdated nor will be soon in the many version-specific tech details it does include; unlike many other books available it waited until Drupal 7 came out and it even was updated in the last hour to reflect the latest Views 3 user interface. This book is a solid foundation for years to

"The vast majority of successful major crimes against property are perpetrated by individuals abusing positions of trust." -- Lawrence Dalzell

Working...