Ready to watch this entire course?
Become a member and get unlimited access to the entire skills library of over 4,900 courses, including more Web and personalized recommendations.Start Your Free Trial Now
- View Offline
- Configuring the new Dashboard
- Using contextual link controls
- Exploring new themes
- Reviewing the new modules
- Understanding the expanded block system
- Using images in content
- Allowing users to delete accounts
- Testing modules with the Testing module
- Building themes using Drupal Gardens
Skill Level Intermediate
The familiar iceberg metaphor applies to Drupal 7's improvements. Most of what's there is hidden from view. This series mostly focuses on changes to how you administer Drupal. That happens mostly through Drupal's own browser-based interface. Now we're going to survey changes to how you program Drupal modules using Drupal's Application Programming Interface or API as it's better known. Now, I have to point out that I'm not a developer myself and this video will only go over the changes very superficially. But we will go over all of the important ones.
The best way to get an overview of the API changes since Drupal 6 is by going back through the release notes of Drupal 7's development versions. To do that, go to drupal.org/project/ drupal and then scroll down underneath where you see the release numbers and say View all releases, because the ones you see up here are only the most recent ones. Once you're there, you read backwards in time and see what the most recent versions were that were released. To narrow it down to just one API version, you would click it up here, in this case, Version 7, and click Apply.
Then you see we have alpha7, alpha6, and so on going backwards in time. Click Read more at the bottom if you want to see back even further in time. As always, you can find complete technical documentation on Drupal's API at api.drupal.org. Once you're there, be sure to click on the Drupal 7 tab, or if you like, you could just go to api.drupal.org./api/ 7 as you see in the browser bar here. Let's talk very briefly about some of the most notable changes to Drupal's API.
The first big change is the Testing module. This is what was formerly known as Simple Test and you can still get that at drupal.org/project/simple test. It comes with many testing scripts to test the built-in modules with Drupal, and it will run scripts that you create against any modules that you create. We demonstrated this in the video on the Testing module in this series. To learn how to develop your own test for the Testing module, a good place to start is the Documentation for Simple Test, which is again on the Simple Test page.
The next big developer change in Drupal 7 is the database layer. Previous versions of Drupal could really only connect to a certain limited list of databases easily. To connect to any other databases, you had to do quite a bit of programming. In Drupal 7 however, that database connection has been abstracted and so now you can connect Drupal to any database, as long as there is a PDO driver. You would then get a Drupal database driver if it exists, and if it doesn't, you can write them fairly easily. You could learn about PDO drivers at the URL on your screen, php.net/manual/en/pdo.drivers.php and you can get more details about programming those Drupal database drivers at drupal.org/node/310069.
The third substantial change in Drupal 7 is RDF or the Resource Description Framework. We talked very briefly about this in an earlier video when I was showing you what the new modules were. RDF lets you describe your data better to other sites. For example, if we were to go to Google and type in a movie title, let's say, burn hollywood burn alan smithee film - one of my favorite films, by the way - Oh! It only got two stars. Well, the interesting thing here is that you can see what the rating is, because that was transmitted from IMDB to search engines through RDF probably.
Basically, it lets your site define what information is and not just that it is information. The next big change in Drupal 7 is there are now better installation profiles. Now, we haven't talked very much about installation profiles, but we will talk about them when we go on to the video about other versions of Drupal. Essentially, Drupal has split in a way. There is the core Drupal, which people consider now more of a platform on which you can build things, and then there are the products that people build from Drupal. One example of such a product is OpenPublish, which is a version of Drupal, which has additional modules and so forth, that lets you set up a new site very easily.
In any case, these installation profiles are now developed a lot like ,odules, and you can learn about this at the URL on your screen. The next big change, this will be a big one for those of you who like all sorts of visual effects in your sites, is jQuery and some other pieces are now part of drupal Core. The big one is jQuery UI, which gives you all that visual oomph, that is, things appearing and disappearing on the screen. One example of that is when you're editing a node and you say that you want to have a menu link to that node, you click in the checkbox and then all of the controls appear, that is, they don't clutter up the screen until you say yes, I actually want to see the controls.
So, that's what's happened between Drupal 6 and Drupal 7. If iou want to see the future, you can get a sense of it by referring to a blog post that Drupal founder Dries Buytaert wrote about Drupal 8. He wrote it all the way back in November 2009 before Drupal 7 was ready for release. But at that point, he already had a pretty good sense of what the next steps would be. You can go and take a look at it at buytaert.net/8-steps-for-drupal-8. One thing that's apparent from his post is how Drupal 7's improvements are not only useful for developers now, but how they are important stepping stones for Drupal's continual improvement into Drupal 8 and beyond.