Blogs
Migrating data in Drupal 5 to 6 using Table Wizard and Migrate (Part 4 - Product Nodes)
Product nodes
So the next step is bringing in the product nodes. As I mentioned in the company node migrate post, I have some custom text fields with taxonomy terms in them, as well as a regular taxonomy, and a node reference field (for the company that makes the product).
The custom text fields' data and the regular taxonomy terms must get moved into new Content Taxonomy fields. The node reference must have its node id number updated to get the new company node id.
Moving imagecache presets to a module
Quick post to show you how to move your Drupal 6.x imagecache presets to a module. This is for imagecache-6.x-2.0-beta10 or higher.
Create your presets in Drupal. Once they're all done, go to the ImageCache list page and click the export link next to the first preset. Copy the code presented to you, and paste it into your module using a function called hook_imagecache_default_presets(). Add a return $presets at the end of the function and save the module.
Migrating data in Drupal 5 to 6 using Table Wizard and Migrate (Part 3 - Company Nodes)
After importing taxonomies and users, now I need to bring in the actual nodes. First thing to do is remove the primary key option from the node table's vid field. Remember, Table Wizard only works when the table has a single primary key.
Alright, so the things that need to be updated during the migrate are the taxonomy terms for each node, any node-reference fields (user-reference fields are fine as-is because we simply copied the existing user base to the new site), and our meta tags from the nodewords module.
Migrating data in Drupal 5 to 6 using Table Wizard and Migrate (Part 2 - Users & Profiles)
Well, it looks like the users are pretty simple to do. Just overwrite the Drupal 6 profile_fields, profile_values, role, users, and users_roles tables with the Drupal 5 ones. No need to do any importing (which would have been pretty complicated with all the profile values in there).
Couple of things to watch for though:
Migrating data in Drupal 5 to 6 using Table Wizard and Migrate (Part 1 - Taxonomies)
This will be the first in a few posts on how I am trying to move data in a series of Drupal 5 sites to one Drupal 6 site.
2010 already??!!
Gee, what happened to 2009? I have been so busy with other things, this website has definitely been lacking some attention. Heck, its still running on Drupal 5! Now that Drupal 7 is in alpha release, I guess I better start work on upgrading this baby to D6 (or maybe I'll just wait until 7 gets released - procrastination 101).
Here's a couple of cool modules/themes that I have discovered in the last little while, and that I now use on most sites I build:
Final straw!!
OK, that's it. I've had enough of those damn comment spammers. Its not bots anymore, unless they've figured out a way to beat the random word Captcha, which is highly unlikely. So, most likely, its some #^@%$#^ getting paid to do this. The only way to stop these morons, is to not allow ANY URLS in a comment. So don't even try posting a link, as it will immediately get marked as spam. Sorry to everyone else, but I'm just tired of these people. Until someone invents a way for me to push a button and blow them all to hell and gone, this is the way it has to be.
/rant
Allow certain roles to bypass Post Preview when it set as required
On a client's site, the Post Preview option is turned on to reduce the amount of bad posts. However, as an admin, this is a real pain - I hate having to Preview first and then Submit. So I did some digging and found out a couple of other people are also interested in a solution. A chap by the name of Markus Petrux has even released a small module (for 4.7) that allows certain roles to bypass the forced preview. You can select which roles in the Access Control page. His module can be found here.
Beware of the Domain Registry of Canada/America "scam"
I am writing this as a warning to everyone who owns a domain and doesn't want to get ripped off.
There is a company called The Domain Registry of Canada (DROC) that does something called "domain slamming". What they do is send domain owners a letter saying that their is going to expire soon and to avoid losing it they should renew it immediately. If you do, you actually transfer your domain to them, and end up paying 5 times more for your domain. They charge $40 per year for a .com, but you can easily find it for around $8 elsewhere.
Adding an "active" CSS class to the <li> element in menus
I seem to keep finding different ways to add an "active" CSS class to <li> elements in menus. I must have been a bit dense, but it took me a little while to figure that menus are displayed using different methods, hence they need different ways to add in the extra class. Here are the methods:
- Using theme_menu_tree e.g. Navigation menu, any menu shown via a block.
