Dries Buytaert on Drupal

On the eve of next week's DrupalCon, Dries Buytaert, the creator of Drupal, talks to Oliver Lindberg about developing and designing for Drupal and the future of the content management system

As a university student in Belgium, Dries Buytaert created the free and open source content management system Drupal in 2000, and has remained its chief maintainer through seven major versions. In 2007 he co-founded Acquia, a company for Drupal answers, tools and support, which now has over 120 employees and has received $38.5million in venture funding.

Developing for Drupal

.net: Let's say I'm a new developer who knows PHP and CSS, but is new to Drupal. How should I approach it?
Dries Buytaert: Programming for Drupal is no different from any other kind of programming: You have to educate yourself first. Drupal has its own architecture and APIs, along with programming standards and best practices that the we've come to call "The Drupal Way". These practices developed over many years and are based on the experiences of thousands of developers. So learning about them, along with the APIs and architecture, is the best way to avoid mistakes.

Also realise that Drupal is not only a CMS: it's also a framework. Learn about the different subsystems and modules it makes available to you. A big part of developing for Drupal is that you shouldn't have to reinvent the wheel: You want to leverage as much as you can. For example, there's usually no need to embed SQL queries directly in your code or write display routines for the results, because there's a popular and mature module called Views that does those things. That's typical for Drupal: you can assemble existing components rather than writing a lot of code.

.net: How can I create a cracking Drupal site with a very tight budget?
DB: Drupal itself is free, of course, so anyone can just download it and start building. If you're building for a specific purpose — for a church, a school or a conference, say — you could start with one of dozens of Drupal "distributions" that includes features common to your purpose. Really, you can build a complete and distinctive site within a couple of hours with some of those distributions.

My company, Acquia, wanted to make it easier to build sites overall. So we launched a hosted version of Drupal called Drupal Gardens. It's essentially what WordPress.com is to WordPress: It includes a curated set of useful and pre-configured modules, and takes care of all the hosting and updating hassles. It also has a point-and-click, graphical theme builder, so you don't have to know CSS to make the site look good.

.net: What are the benefits of hosting Drupal in the cloud?
DB: Drupal gains the same benefits as other server-based application when it's hosted in the cloud: dynamic scalability, failover and so on. One reason Drupal is especially well-suited to cloud hosting is that it's used a lot in the media industry where they have to deal with unexpected traffic spikes. One good example is Al Jazeera, the news organisation in the Middle East that was hammered by traffic during recent uprisings in the area. They were running Drupal in the cloud (actually on my company's platform, Acquia Cloud) and their site performed well. Because it was on the cloud, we could dynamically scale them up on more hardware.

Drupal comes to town: DrupalCon London features a ton of sessions, talks and workshops

Drupal comes to town: DrupalCon London features a ton of sessions, talks and workshops

Designing for Drupal

.net: Why is it such a struggle to make HTML5 work with Drupal?
DB: I don't think it is! In Drupal 7 there's a contributed module called HTML5 Tools that works together with the HTML5 Base theme to override Drupal's default markup with HTML5 markup.

Going forward, I've already made HTML5 one of the top initiatives in Drupal 8. (The other four focus on configuration management, design, web services, and multilingual application.) In short, Drupal 8 will output HTML5 by default; we already have a few patches in the Drupal 8 development branch that introduce those elements.

.net: How will theming be made easier in the next release of Drupal?
DB: We want to raise the bar for design in a big way in Drupal 8 - that's why it's one of the top five initiatives. Besides implementing HTML5 and generally cleaning up the HTML and CSS markup, we'll introduce a new design to Drupal 8 with the goal of attracting more designers by showing Drupal design in its best light.

.net: How can you use the Theming API the best way?
DB: That's a big subject! There are courses on how to use the theme system in the best way - everything from books to video courses to multiday classes to private training. That's one of the great things about how Drupal has grown: There's a whole ecosystem of training resources now, teaching a rich history of best practices. We’ll continue to listen and work with themers to make Drupal easier and better the theme for.

Drupal's future

.net: What’s next for Drupal? How’s work on Drupal 8 going and what can we expect?
DB: The focus for Drupal 8 is around the key initiatives I mentioned earlier, and also an emphasis on making Drupal the go-to platform for mobile applications. That doesn't mean it will replace native iOS or Android apps, of course. They're best for certain purposes, although Drupal 8's native HTML5 will also work well as the presentation layer for some apps.

The bigger issue is that mobile apps rely on web services. That happens to be something Drupal already does very well, and will do even better as we go forward. I want Drupal to natively output content in multiple formats: not just HTML, but also XML, JSON and so on. Applications should also have the ability to call into Drupal with a RESTful API to retrieve and execute actions on content.

The Drupal 8 web services initiative will make that happen as part of Drupal core. It will force us to look at how Drupal stores data and improve the separation between structure and output format. A side effect will be better import, export and CRUD operations.

.net: How does Drupal plan to stay a leader in the open-source software market against such competitors as WordPress?
DB: A lot of people in the community believe that WordPress is a competitor, but I don't think that's healthy. While there's some overlap, WordPress and Drupal serve different target audiences: WordPress is great for blogs and simple websites, Drupal is better for bigger websites with more complex needs. At the end of the day, WordPress and Drupal are both open source, so we're fighting the same fight.

The true competitors — and the ones where the biggest opportunities lie — are proprietary CMSes such as Vignette, Sitecore, Fatwire, Jive and SDL Tridion. Overall, the community has a decent understanding of how WordPress and Drupal compare, but not many people really understand how those others work, or what Drupal's advantages and disadvantages are in relation to them. Yes, WordPress is a competitor, and we should learn from them. But we can't let that distract us from the bigger potential win. Also, those proprietary systems are low-hanging fruit. We see Drupal win a lot in legacy migrations, because it replaces them so easily.

.net: You say that Drupal is fighting "the same fight" as other open source projects. Why is open source important?
DB: Open source software often provides a better value proposition for users. It's pretty hard to argue against that, although proprietary software vendors keep trying. What's more interesting to me is that open source software has a better development methodology. About a thousand people contributed code to Drupal 7, with many thousands more testing, commenting, and documenting it. That leads not only to better code, but to more innovation. Proprietary software vendors, with their small engineering teams, simply can't come close. As a result, successful open source projects like Drupal are not only cheaper, but also technically superior compared to proprietary alternatives.

Open source methodology works best when you have a large market, as Drupal does for CMSes. There, open-source products commoditise and democratise the market — at the expense of expensive, proprietary solutions. Niche markets do well with proprietary software, though, because there's not enough interest in them to build the community that open-source development thrives on.

In my position as chief technical officer at Acquia, I see Drupal beating out those proprietary vendors every day. New sites are building on it, and old sites are migrating to it. I think that's good for anybody who cares about code quality, development ease, and software freedom.