FireCore LLC designs powerful media center software aimed at complementing a number of popular Apple hardware products. FireCore has been routinely featured in a number of major publications such as: Macworld, Popular Science, Gizmodo, Engadget and many more. They needed to consolidate three disparate web applications into one unified platform.

FireCore
Why Drupal was chosen: 

FireCore's previous site utilized three different software packages:

  • osCommerce
    The e-commerce part of their previous site was run with osCommerce.
  • WordPress
    The site blog was run on WordPress
  • phpBB
    Their support forum was driven by phpBB. Many of the users were also customers in their osCommerce store database, having separate accounts on both systems.

We (Rehab Creative) were approached by FireCore about creating a new site, ideally merging the three systems into one. This project was a perfect fit for Drupal and Ubercart, and after a few brief discussions, FireCore agreed that Drupal sounded like a great platform to work with. The slick visual design was provided by Jack Herbert and the PSDs were handed off to us to cut out to a Drupal theme.

Describe the project (goals, requirements and outcome): 

osCommerce vs. Ubercart

One of the main advantages of Ubercart over osCommerce is Drupal itself. A Drupal-based commerce solution provides content management, commerce capability, forum, blog and user management all in one proven package with a deep base of contributing users and modules. Using osCommerce as their e-commerce engine, FireCore needed to utilize two other software packages (WordPress and phpBB) to achieve all requisite functionality.

Additionally, FireCore expressed that many of the osCommerce contributions the site depended on ("contributions" are the closest thing osCommerce has to modules) required adjustments to the osCommerce core and often specific contributions would require core changes that would conflict with other contributions. This presented problems with both implementing relevant contributions and with keeping the osCommerce core up to date.

Challenges

The migration from osCommerce to Ubercart alone was a unique challenge due to the nature of the file-downloads and variable expirations sold on the site. The two carts handle purchased file downloads fundamentally differently, and reconciling those differences was more involved than a traditional physical-goods store migration would have been.

On top of that, many customers also had accounts on the phpBB-based forum and even on the WordPress blog for commenting on blog posts. This meant that we had to reconcile users from the three systems into the single Drupal user table, while maintaining proper associations of user->order, user->forum posts, etc.

Approach

The initial migration was done largely via the following modules:

While the modules above greatly helped expedite the import of many of the larger content items, the user consolidation and proper linking had to be handled largely via some custom PHP/MySQL logic outside of Drupal.

The migration and consolidation of orders, users, phpBB forum posts, etc were numerous and complex, so much so that it would be unreasonable to go into great detail on each front. However, purchased file downloads, and a user migration/consolidation issue presented two of the more interesting migration challenges, so an extended summary of these follows.

Migrating File Downloads

One of the more difficult challenges resulted from the way Ubercart handles purchased file downloads. Under Ubercart, file downloads are granted to users upon purchase, but without association to an order ID. The file downloads table in Ubercart has a list of all the file downloads granted to users (along with expiration dates, etc), but there's no link back to an order. Additionally, the order table doesn't maintain any association with a file download granted to a user. With osCommerce, the file download is associated with an order just like any standard product on an order.

FireCore software is available for purchase with various expiration levels. Customers can purchase software updates for one, two or three years, and a lifetime option. Each of these choices represents a product feature under Ubercart. When a user purchases a file with one of those time periods, they're purchasing an Ubercart product with a product feature that dictates what file they get access to, how long the download is good for, how many downloads they are allowed and the name of that product feature.

With Ubercart, the product feature component is rather complex and stores these product attributes in a product feature table. The file downloads table then has a field for a product feature so every file download purchased by a user knows whether it was purchased for one year, two years, etc. This means that the product features had to be created in the Ubercart database before the file downloads table could be populated with a user's purchased files. While the expiration field is an explicit field in the file downloads table, the description of the file download ("1 year of updates") is stored as part of the product feature, not in the file downloads table itself.

Under osCommerce, these purchased files are stored with the expiration date of the download, but without any notion of a "product feature", so the only way to know if the download was purchased with "2 years of updates" was to look at the expiration and manually map those expirations to the proper Ubercart product features.

The initial migration using the modules outlined above handled the migration of the orders table just fine, but did nothing to bring the users' file downloads across. At this point, we wrote up some PHP/MySQL to grab the files from the osCommerce database and properly add them to the Ubercart database. This script needed to assign the proper UID as well as the aforementioned mapping to assign the appropriate product feature for the file download.

Consolidating store and forum users

The phpBB2Drupal module flawlessly imported users and their posts while correctly handling users that already existed in the Drupal database following the store migration. Many osCommerce customers also had accounts in the phpBB forums, using the same email address. We used the osCommerce migration as our 'master' for the users, then performed the phpBB2Drupal migration after.

This created new users where necessary and utilized the existing users when the email address was already in the system. The only problem here was that, for users with accounts on both legacy systems, the "Joined", or "Member Since" dates were being decided by their osCommerce user account, since that account was the master as far as our Drupal site is concerned. To remedy that, we had to manually loop through the legacy phpBB database and properly overlay the legacy Join dates on top of the user accounts in the new Drupal database. After that, all the Drupal forum user accounts had the right Join dates, helping ensure a more seamless transition for existing forum users when they began using the new site.

Checkout customization

FireCore CheckoutFireCore had very specific requests for the layout of the checkout page. The legacy osCommerce site utilized a similar checkout page which provided a simplified 3-step flow: 1. Check your Cart 2. Enter Contact Details 3. Select Payment Method

Ubercart natively wants to group the checkout page by some default "panes", and those didn't line up with the desired flow. The checkout page needed to be significantly altered both in grouping and order of presentation. Fortunately, Ubercart provides hooks for this very manipulation. We were able to precisely achieve the desired layout by using some standard hook_form_alter functions along with Ubercart's hook_checkout_pane. The hook_checkout_pane methods we used essentially boil down to what you can see on Stella's website, only expanded significantly over what is shown there.

Forums

FireCore ForumsUsing the Advanced Forum module, and some custom templates, we created a forum with a look and feel more in line with the structure existing users had come to expect on the phpBB forum.

Additionally, we added highlighting to moderator posts to provide 'official' replies with visual separation from those of general users.

Additional Functionality

In addition to the primary functions of the site outlined above, we also seamlessly integrated with Zendesk (Zendesk remote authentication module), securely served purchased file downloads from CloudFront using the Ubercart CloudFront module (with some of our own tweaks), and implemented a number of custom modules to improve the checkout flow and product presentations in general.

Expanding File Downloads

FireCore needed a way to manually adjust the expiration of purchased files for various reasons, so we wrote a module to give the site admin the ability to search for user downloads by username or email, then manually edit, delete and add file downloads to the user's account.

FireCore User Account
Ubercart natively allows admins to add a file download to a user account, but it doesn't take into consideration the various product features you've defined in your store. You can manually grant a user access to a file, and you can set an expiration date on that download, but you can't assign it the product feature "2 years of updates". The only practical problem presented by omitting the product feature is that the user won't see "2 years of updates" presented on their file downloads page. Instead, they'll only see the file name, and the expiration date. In our case, "2 years of updates" is actually an important part of the purchased product name, so we added the ability for the site admin to manually add a file download to a user account with any predefined product features.

File downloads and past orders are clearly presented to users directly on their account page. Upgrade offers and expiration notices are also conditionally displayed to the user on this page depending on the product features and expirations on their existing purchased downloads.

The site is now serving more pageviews than ever before, and the three unified systems (store, blog, forum) are working together seamlessly.

Technical specifications

Why these modules/theme/distribution were chosen: 

While the modules above greatly helped expedite the import of many of the larger content items, the user consolidation and proper linking had to be handled largely via some custom PHP/MySQL logic outside of Drupal.

Community contributions: 

During this build we contributed patches and improvements to the Ubercart Addresses module as well as the Zendesk remote authentication module.

Organizations involved: 
Team members: 
Project team: 

Jack Herbert provided the excellent visual designs for this project.

Product Page
Checkout Page
Customized Forum
User account page
Sectors: 
E-Commerce
Entertainment
Technology

Comments

Tezza’s picture

Hi Danny

Great site, thanks for posting this case study.

I have asked the Case Studies Team to consider it for promotion to the 'Featured' page.

#1666252: Promote 'Fire Core - Drupal / Ubercart File Download' to Featured

If this appeals to you (or even if it doesn't!) please follow the link above and post a reply.

Terry

songkrod_it’s picture

good