Upgrading Drupal 5 to Drupal 6, Part 1
Acording to A Survey of 2,368 Drupal Sites a large number of websites are still running Drupal5 so i think it's a perfect time and perhaps the last change to start planning for safely upgrading our good old Drupal 5 websites to Drupal 6 (If any remained), Drupal 5 will be deprecated as soon Drupal 7 final comes out. Some module maintainers already removed Drupal 5 releases from their projects which is a trouble for website running Drupal 5. Drupal 7 final release is not out yet and i guess that it takes about 2 years until Drupal 7 becomes as solid as Drupal 6 and also most modules upgrade to this new version that's because too many awesome new features included in Drupal 7 and they require quite some polishing.
Why not wait for Drupal 7 and directly upgrade? . As long as i know it's not possible to skip Drupal 6. You'll have to upgrade to Drupal 6 and then Drupal 7 if you want Drupal to do it automatically for you. Besides if your site is critical and you want an stable site i guess you'll have to wait for about 2 years until everything is ready (Including contributed modules port). And also in my case there are certain features i should implement that are not available in Drupal 5, and reimplementing them requires much more time than upgrading the website. i only have one website left with Drupal 5 , it didn't worth upgrading before but today after i checked upgrade status to see the status of the contributed modules i used on the website, they've been either upgraded , included in Drupal 6 or replaced by better alternatives.
Upgrading Drupal has never been easy, not because of Drupal itself but because of the fact that Drupal's strength relies mostly on its modules and we usually install dozens of them on each website (I have websites with over 90 modules installed, you may have even more :) ). And not all of these modules are well maintained. Switching from one module to another is not easy , specially for complex modules. that's what makes upgrading sometimes very time consuming, not to mentioned the testing process!!
As i mentioned before upgrading is time consuming and with lots of module i've installed on this site it's going to take even more. since my time is limited i should pick the fastest way so i decided to divide the modules into two groups, Critical and Non Critical (Like some administration modules). This way i can launch the new version of the website and then upgrade the remaining modules one by one.
Planing
Perhaps the most important part of the upgrade process is planning. As you may already know, Drupal is also a Framework which means that on each release both users and developers have to deal with some fundamental changes. It's actually Drupal's great advantage. So upgrading Drupal is not only about updating it's also about improving, changing, customizing and also sometimes simplifying. For this reason planning is even more important. You might be able to find far better alternatives for your current modules, get rid of many core/module patches, simplify the modules you've developed or customized, by benefiting from new core and contributed modules' features.
The first part of planing is reading more about the new Drupal version and its new features. And the next part is checking all contributed modules and finding better alternatives which i'm going to describe here. So we need to install and use the awesome upgrade status module.
Check the status of contributed modules
Patches
I usually patch both modules and Drupal core specially when i find a bug. and almost always contribute this patches back to the community. It's important to keep track of this changes otherwise i may break the site with every core or module update! There is a young module called patchdoq by @doq which is going to simplify patching , right now it needs our love :)
Most of the time i use version control system and follow these steps :
- Making the patch
- Testing it
- Submit the patch to the modules' issue queue and keep the issue link
- Commit the patch and use patch keyword , simple description of what it does and a link to the issue on issue queued.
Before we start lets have a look at the contributed modules and see how difficult it's going be be , i can simply check the history of the module using VCS and see whether there is any patch keyword on history, if i find anything since i already have a link i can check whether its been committed or not. If you're not using VCS you can use Drupal.org's advanced search and enter your username in "Participant" or "Submitted by" field and fill in the project name field.
Core patches : i've had plenty of them like this one Very expensive calls drupal_lookup_path but they're no longer required for Drupal 6
Modules
Critical (Check list)
Here is the list of modules i used on this particular website and their status, i'm sure that it will come handy for anyone willing to upgrade. i mentioned alternatives for deprecated module as well.
I sorted the modules by their dependency because it's important to upgrade all the module's dependencies first.
Note : I usually use Devel Macro module to repeat the configuration on the production site.
Views by @merlinofchaos , @dereine , @dww and many others : The Views module provides a flexible method for Drupal site designers to control how lists and tables of content (nodes in Views 1, almost anything in Views 2) are presented. Traditionally, Drupal has hard-coded most of this, particularly in how taxonomy and tracker lists are formatte ...
- Ported : Yes (Can't imagine Drupal without this one :) )
- Installed version : 5.x-1.6
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-2.8
- Dependency for the other modules : Yes
- Better Alternatives : You kidding?
- Special note for upgrade : Old views should be converted via admin/build/views/tools/convert.
Token by @eaton , @greggles and many others : Tokens are small bits of text that can be placed into larger documents via simple placeholders, like %site-name or [user]. The Token module provides a central API for modules to use these tokens, and expose their own token values ...
- Ported : Yes
- Installed version : 5.x-1.13
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.12
- Dependency for the other modules : Yes
- Better Alternatives : No
- Special note for upgrade : No
jQuery Update by @jjeff , @webchick and the others : This module facilitates an upgrade of jQuery in Drupal core and allows other contrib modules to rely on a newer jQuery version ...
- Ported : Yes
- Installed version : 5.x-2.0
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.1
- Dependency for the other modules : Yes
- Better Alternatives : No
- Special note for upgrade : No
Pathauto @greggles , @Freso , @mikeryan and the others : The Pathauto module automatically generates path aliases for various kinds of content (nodes, categories, users) without requiring the user to manually specify the path alias. This allows you to get aliases like /category/my-node-title.html instead of /node/123. The aliases are based upon a "pattern" system which the administrator can control ...
- Ported : Yes
- Installed version : 5.x-2.3
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.2
- Dependency for the other modules : Yes
- Better Alternatives : No
- Special note for upgrade : No
Content Construction Kit (CCK) by @yched , @markus_petrux , @KarenS and many others : The Content Construction Kit allows you to add custom fields to nodes using a web browser ...
- Ported : of course it's ported :) , Who can live without CCK?!
- Installed version : 5.x-1.10
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-2.6
- Dependency for the other modules : Yes
- Better Alternatives : No
- Special note for upgrade : No
Javascript Tools by @nedjo , @ray007 , @m3avrck and the others : Javascript Tools provides a common set of methods extending those available in Drupal core (drupal.js) for Javascript and AJAX module development in Drupal ...
- Ported : Yes
- Installed version : 5.x-1.2
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.0
- Dependency for the other modules : Yes
- Better Alternatives : No
- Special note for upgrade :No
Date by @KarenS , @hass and many others : The date module is a flexible date/time field type for the cck content module which requires the CCK content.module and the Date API module ...
- Ported : Yes
- Installed version : 5.x-2.8
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-2.4
- Dependency for the other modules : Yes
- Better Alternatives : No
- Special note for upgrade :No
Boost by @Arto , @wulff , @mikeytown2 : Boost provides static page caching for Drupal enabling a very significant performance and scalability boost for sites that receive mostly anonymous traffic ...
- Ported : Yes, Not only ported but thanks to its recent very active maintainer @mikeytown2 it's in a very good shape
- Installed version : 5.x-1.0
- Patched : Yes, but all the patches committed at least to 6.x version by the maintainers Remove symlink creation. Let each path have own file
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.18
- Dependency for the other modules : No
- Better Alternatives : No
- Special note for upgrade : New version of boost are quite different, complete uninstall/reinstall is easier. Also make sure that you've updated .htaccess and create cache folder when moving to production site. admin/settings/performance/boost set cache folder to temp/boost
Comment Info by @Cainan , @mfer : This module allows for anonymous guests to keep persistent comment info between comment postings ...
- Ported : Yes, Couldn't be better, Ported to core.
- Installed version : 5.x-3.1
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : In Core
- Dependency for the other modules : No
- Better Alternatives : No
- Special note for upgrade : No, it just works
CAPTCHA by @wundo , @soxofaan , @Rob Loach and lots of others : A CAPTCHA is a challenge-response test most often placed within web forms to determine whether the user is human. The purpose of CAPTCHA is to block form submissions by spambots, which are automated scripts that post spam content everywhere they can ...
- Ported : Yes, Ported and also has a very active maintainer @soxofaan
- Installed version : 5.x-3.2
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-2.1
- Dependency for the other modules : Yes
- Better Alternatives : There are several alternative like Mollom and recaptcha (check out module's page for more alternatives) but since i need something simple i prefer the bundled captcha image.
- Special note for upgrade : Currently this module has some serious issue with caching modules please join us to fix this issue. Other than this issue it work fine
Calendar by @KarenS and the others : This module will display any Views date field in calendar formats, including CCK date fields, node created or updated dates, etc. Switch between year, month, and day views. Back and next navigation is provided for all views ...
- Ported : Yes
- Installed version : 5.x-2.7
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-2.2
- Dependency for the other modules : No
- Better Alternatives : Not that i'm aware of
- Special note for upgrade : New Calendar module benefits from Views argument feature, therefore simply converting its views does not work. Arguments should be added. Calendar's default views is a good example. The difference between old calendar views and the new is much so i found it easier to use views export feature and use the default views as a template
Lazy image loader by @sinasalek : Websites with lots of images on a single page might take a long time to load, and it sometimes annoys visitors. for fixing this problem this module loads only the images that are visible to or requested by visitors and the other images loads only when visitor scroll downs to them (This is the default behavior there are other options available live mouseover, mouseclick etc) ...
- Ported : Yes
- Installed version : Custom Module
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.1
- Dependency for the other modules : No
- Better Alternatives : No
- Special note for upgrade : No, default configuration works just fine
Voting API by @eaton , and the others: VotingAPI helps developers who want to use a standardized API and schema for storing, retrieving, and tabulating votes for Drupal content ...
- Ported : Yes
- Installed version : 5.x-1.6
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-2.3
- Dependency for the other modules : Yes
- Better Alternatives : Yes
- Special note for upgrade : No
Fivestar by @quicksketch , @ezra-g and the others:
- Ported : Yes
- Installed version : 5.x-1.16
- Patched : Yes, but all the patches committed by the maintainers
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.19
- Dependency for the other modules : No
- Better Alternatives : No
- Special note for upgrade : It has some strange issue warning: Division by zero which has been reported several types, but it seems that it still exists. it's not critical bug however
admin/settings/fivestar select oxygon theme
Image Picker by @hutch and @notsleepy: The Image Picker module is an image upload feature modeled after the image upload currently built into Wordpress but with a few improvements ...
- Ported : Yes
- Installed version : 5.x-2.2
- Patched : Yes, Imageinsert does not work and no javascript error! Not sure wether it's applied or not
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-2.6
- Dependency for the other modules : No
- Better Alternatives : Yes , the combination of filefield, imagefield, insert, imagecache module
- Special note for upgrade : No
Javascript Aggregator by @derjochenmeyer , @Rob Loach : The aim of the JavaScript Aggregator module is to improve performance of your site with less server requests and bandwidth per page. In Drupal 5, all the JavaScript files will be aggregated into one file and optionally minified. JavaScript aggregation was brought into core with Drupal 6, so the Drupal 6 version of this module goes one step further to minify that file. ...
- Ported : Yes
- Installed version : 5.x-1.5
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.3
- Dependency for the other modules : No
- Better Alternatives : Support File cache but it's too much
- Special note for upgrade : Configure it here admin/settings/performance
Nodewords by @kiamlaluno , @Robrecht Jacques , @hass and the others : This project allows you to set some meta tags for each Drupal page.
- Ported : Yes
- Installed version : 5.x-1.13
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.11
- Dependency for the other modules : No
- Better Alternatives : No
- Special note for upgrade : Make sure to enable at least one of the sub modules that come with Nodewords
Notify by @matt2000 , @beginner , @RobRoy and the others : The notify module allows users to subscribe to periodic emails which include all new or revised content and/or comments much like the daily news letters sent by some websites ...
- Ported : Yes
- Installed version : 5.x-1.3
- Patched : Yes, "limiting number of result in notify module" and it's not committed and also notification of unapprouved comments... which is not committed
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.0
- Dependency for the other modules : No
- Better Alternatives : No
- Special note for upgrade : Check the configuration admin/settings/notify and also users' configuration user/5/notify
Page Title by @nicholasThompson , @JohnAlbin , @robertDouglass and the others: The word "title" is a bit overloaded. Every piece of content in Drupal has a title, and so does every page. The page title is the one found in the HTML head inside the <title> tag. It is also used on SERPs (Search Engine Result Pages) and can greatly enhance your websites SEO (Search Engine Optimization) ...
- Ported : Yes
- Installed version : 5.x-2.3
- Patched :No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-2.3
- Dependency for the other modules : No
- Better Alternatives : No
- Special note for upgrade : No
Recent Blocks by @cotto , @Frank Ralf and the others: No ported but it's easily achieve using Views and Views UI
- Ported : Yes
- Installed version : 5.x-1.3
- Patched :No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : Non but the maintainer say 6.x-1.x-dev should work
- Dependency for the other modules : No
- Better Alternatives : Yes, i'm going to use views instead
- Special note for upgrade : No
Recent Changes by @rötzi , @toemaz : The recent changes module let's you track all editing on your site. A page is provided with a list of all revisions and comments in chronological order.
- Ported : Yes
- Installed version : 5.x-1.2
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : None but 6.x-1.x-dev exist, don't know whether it works or not.
- Dependency for the other modules : No
- Better Alternatives : Yes, i'm going to use views instead
- Special note for upgrade : No
- Ported : Yes
- Installed version : 5.x-1.0
- Patched : Yes and all committed, "Don't force frame" and "Show URL in right frame" optoins issues and Some images link is not valid when has i18n module enabled or is inside admin
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.0
- Dependency for the other modules : No
Better Alternatives : Yes, there is a better alternative by the same developer Navigate. This new module unlike Super Nav does not use Frames and it's also more customizable. Drupal 6 also has lots of new administration modules like Teleport , Admin , Admin Menu, etc
- Special note for upgrade : No
Scheduler by @Eric Schaefer , @skiminki , @AjK and the others : This module allows nodes to be published and unpublished on specified dates.
- Ported : Yes
- Installed version : 5.x-1.18
- Patched : Yes, commited
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.6
- Dependency for the other modules : No
- Better Alternatives : No
- Special note for upgrade : This module used to have some critical issues with publishing nodes incorrectly , so testing it again is very important
Excerpt by @hayesr , @hanoii and the others : Excerpt module allows you to enter a separate excerpt/summary/teaser for a node, which does not have to be a cut off version of the body.
- Ported : Yes
- Installed version : 5.x-1.3
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.1
- Dependency for the other modules : No
- Better Alternatives : No
- Special note for upgrade : No
Tiny Tiny MCE by @Steve Lockwood : Tiny Tiny MCE (TinyTinyMCE) is a Drupal 6 supported module supporting the wysiwyg editor tinymce.
- Ported : Yes
- Installed version : 5.x-1.5
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : 6.x-1.12
- Dependency for the other modules : No
- Better Alternatives : Yes, There is a perfect alternative WYSIWYG
- Special note for upgrade : Should be set here admin/settings/wysiwyg
theme_switcher : A custom module i created for separating view and admin theme more accurately
- Ported : No
- Installed version : Custom
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : No
- Dependency for the other modules : No
- Better Alternatives : Yes, Drupal 6 has its functionality build-in there is also two other modules for more customization Administration theme and System Theme++
- Special note for upgrade : You can set it here admin/settings/admin
Default Filter by @dllh : This module allows you to set default filter formats per node type per role, preventing users from having to tick a checkbox every time they add a new node. This is useful for sites that set the global default to a less rich format to prevent anonymous users from using (for example) full HTML.
- Ported : No
- Installed version : 5.x-2.1
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : No
- Dependency for the other modules : No
- Better Alternatives : Yes, much better alternative is available Better Formats
- Special note for upgrade : Select co-author as well here admin/settings/filters/4
Select smart content for both webmaster and co-atuhor admin/settings/filters/defaults
Smart Line Break Converter by @nschelly : The smartlinebreakconverter will selectively apply the line break converter filter (in the core filter module) based on whether it thinks it's necessary.
- Ported : No
- Installed version : 5.x-1.1
- Patched : No
- Latest Drupal 5's version : Uptodate
- Latest Drupal 6's stable version : No
- Dependency for the other modules : No
- Better Alternatives : No
- Special note for upgrade : No
In the next article i'm going to check the remianing non critical modules and the prepare the development copy for upgrade and finally actuallay doing the upgrade
- Login to post comments