richard's blog

Upgrading Drupal 6 To Drupal 7 For Large Projects

With Drupal 7 just over a year old everyone is starting to wonder when it's time to upgrade Drupal 6 to 7. Although it will continue to run well for a few more years there are many benefits to Drupal 7 from both the interface and development perspectives. This applies especially to large / on-going projects. If you're managing a site like that, what is your strategy to upgrade?

Drupal Blog Modules

Drupal 7 has taken big steps to make the interface easier to use and catch up with Wordpress in that area. But much as we all love Drupal, Wordpress still makes it easier to set up a blog. If you need the power of Drupal but you want a modern blog, here are some modules you can use to enhance the experience. Unfortunately many of them aren't stable in Drupal 7 yet but most of them seem to be close.

Drupal on Nginx - Static File Performance

Recently I've tried running Drupal on nginx to boost performance. Instead of using nginx as a proxy to apache to run php, I use fcgi called by nginx. Of course the static files are served directly by nginx with nothing to get in the way.

To get an idea of how far I could push the server I ran a few tests. Since most of the files requested for a page are static files and I've mostly focused on optimizing Drupal itself so far, I wanted to see how fast it could serve the static files. The configuration was:

Webserver:

Making Drupal Redirect Missing Pages to Another Site

Redirecting missing files and pages to another site is a common trick when migrating a complex site. However Drupal adds another layer to it. The regular server configurations won't work with Drupal, because it already takes over for any URLs that don't exist on the local filesystem. So if you have a new Drupal site and you want to redirect all missing URLs to an old site, how do you do it? All you need is one extra hook in a custom module:

drupal_http_request not sending POST data?

If you're used to writing HTTP requests using cURL, developing with Drupal is nice because drupal_http_request does all the work for you without having to pass a long list of options. Let's say that you need to send some data to another server with POST, and you read the documentation for drupal_http_request. A quick glance at the list of options shows that you could do this:

Creating Alphabetical Filter With "Numeric" Category in Drupal Views Using a Custom Filter Handler

One of the things we love about Drupal is that in many areas you can get 80-90% of the way there just by configuring a few things in the admin interface. But when you need to go all the way with the last small changes, it sometimes requires digging deep into the system in areas that aren't well-documented. I recently came across this when I had to take a View which was built to filter nodes by the first letter of their titles, and modify it so that 0 through 9 weren't separate entries. This demonstrates how you can create a new View filter type to accomplish specialty tasks.

Subscribe to RSS - richard's blog