Sorted.org.nz released - Total Drupal conversion

dman's picture

I recently assisted in a total conversion of that high-profile (also astonishingly high-traffic) Sorted.org.nz to Drupal 5. Released last Sunday.

All the heavy lifting, Design, Content conversion etc was done by the Sparks Interactive team. I'm sure they won't mind me making this announcement partly on their behalf.
I assisted mostly in a remote mentor/sharpshooter role with a few of the tricky bits.

The New/Interesting/Drupal features include

  • Some menu magic - displaying subsection-relevant nav only. Plus activemenu.module and CSS tweaks
  • Incorporation of several years worth of legacy, custom PHP code Sorted Calculators all done in bespoke templating systems and User Session things. All this functionality was 'wrapped' using an updated version of a technique I developed a while ago.
    This thankfully avoided the worst of the re-writing of legacy code, whilst retaining the functionality of several years of user budget data retention. Jas K @ SparksInteractive did the tricky internal bits to the old code, I did the generic Drupal integration.
  • Migrating and blending thousands of user accounts and profile details (hundreds of columns) into becoming compatable with the Drupal user management system. (that was not me, apart from a few pointers on session integration and I'm in awe of the job done on the DB there)

Not a heck of a lot of big add-on modules were used. LoginToboggan, nodeteaser, site_map, jstools(activemenu), relatedlinks, on the front-end.
fckeditor plus some minor custom work on the back.

No CCK, No Views, Not even any real Taxonomy used (tagging for internal content-managment only so far).

There's a couple more features waiting under the hood (like comments), yet to be finalized. And there's probably a few rough corners still to be found on the site if you look hard enough. For now we are bracing ourselves to see how the scaling has worked in a live environment. So far so good...

Plus, from which I hear, the client (NZ Retirement Commission) is very happy with the Drupal back-end and management features.

I just thought that as sorted.org.nz gets so much airtime in NZ some folk might recognise it.
and its ... modified mascot.

Comments

Nice work from all involved

styro's picture

Good to see a high profile NZ site using Drupal :)

It's also a good example of how Drupal isn't just for blogs... It's only the user registration bit that is recognisably Drupal.

--
Cheers
Anton

--
Cheers
Anton

Great work!

Bevan's picture

It's really impressive to see this level of quality drupal development coming out of enzed. :)

Notes from the trenches of sorted.org.nz

Jas K's picture

Being a first time user of Drupal, I was amazed and impressed by its power and flexibility. I was lucky to have such a great mentor to speed up our learning process - thanks dman!

Re. the user data migration, check out the User Import module. It did exactly what we needed, and that, along with LoginToboggan, meant that old users were able to log in to the new website using their old credentials in the old way (email and password), still keep their old username, and have all their saved calculator data as if the site had undergone only a re-skin, rather than a complete rebuild in a new system. Very smooth. :-)

A new Drupal fan!

How'd you do calculators

Bevan's picture

I was just wondering how you implemented the calculators in drupal? Did you use existing modules? How much needed to be custom written?

The calculators are PHP and

Jas K's picture

The calculators are PHP and PHPTAL (legacy code), wrapped into Drupal using dman's wrapper module (see his point 2 above re. a technique he developed a while back).

The calculators use database tables imported in to sit within the Drupal database. The only customisations necessary were the setting up of aliases for accessing them in the way we wanted, some configuration of the wrapper module, and in the calculator code itself, the usage of the new Drupal uid to link to newly imported users in the new system rather than the old system's user uuid.

Most of the other changes I had to make to the calculator code itself were due to the PHP5 and PHPTAL 1.1.8 upgrades, which was a preliminary step before the code was ready to "wrap".

Yeah. The (several

dman's picture

Yeah. The (several generations of) old code was still working, but too challenging to rewrite from scratch into Drupal methodology. No real need to either.
So I treated it as a black-box - setting up an appropriate environment, telling Drupal the old.php files were virtual pages, passing it the page requests straight, then scraping the output. Wouldn't even call it scraping after the headers and footers were removed - just a case of inlining it.

In doing so, I think I can see a pretty generic way of answering the 'how to use third-party applications' questions that come up regularly.

Basically, there was an investment in the existing calculators - and the years of user data therein - that didn't need to be messed with. No, I'm not aware of any Drupal modules that could help much towards replicating what it does. The closest existing thing is questionaire, although there are shades of profile in there too.

did you include (and

Shiny's picture

did you include (and execute) the existing code, or did you proxy it?

Proof-of-concept code linked

dman's picture

As in the code I linked in the OP - the core is mostly:

<?php
 
// Buffer whatever the page does
 
ob_start();

  include(
$file_path);

 
$output .= ob_get_contents();
 
ob_end_clean();
?>

That's cheating ;-)

Shiny's picture

That's cheating ;-)

Interesting, thanks for that

Bevan's picture

Interesting, thanks for that!

New Zealand

Group organizers

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds:

Hot content this week