Blogs

Why use drupal

Recently a client asked me to write an introduction that he could present to his business partners about myself and why I use drupal. Sanitized text of my response is below.

*******

I appreciate the opportunity to share a little about what I do and how I can help your organization.

Theming Drupal with multi class selectors

sometimes it's useful to check for the existence of two classes in an element before applying a style to it. For example, if you have a front page that has a different width sidebar than an interior page, you could use a separate page-front.tpl.php file, kind of overkill of your just changing the width of the sidebar.

Another option is to use what http://www.bennadel.com/blog/680-Defining-A-CSS-Selector-That-Requires-A... calls multi class selectors.

.front.sidebar-left #content{ width:760px; margin-left:436px; margin-right:-1196px;

Startup Weekend is coming to Tacoma, sort of

in
Andrew Fry is organizing a startup weekend Tacoma to be hosted by Suite 133.
 
As a veteran of the Seattle Startup Weekends (hosted by Adobe, Google and Microsoft) I'm looking forward to attending one a little closer to home.

Leveraging Features and Spaces for Drupal Installation Profiles

There are a few ways in Drupal to create "copies" of a Drupal site that you find you want deploy over and over again.
 
These include:
  • Using the Installation profile Wizard (no Drupal 6 version)
  • Features module (can only enable after site has been built out, making it difficult to deploy using Aegir Hosting system)

David Hazel is an individual sponsor of Drupalcon SF

David Hazel is going to Drupalcon San Francisco in April and is an individual sponsor. If your going, being an individual sponsor of Drupalcon is a pretty painless way to support the development of software you use everyday.

Troubleshooting "The GD library is missing or outdated"

Sometimes after installing a drupal site on a new server, or slicehost slice, you'll get a message in the Status Report pages, "The GD library is missing or outdated". If your sure the GD libraries are installed (most likely they are) make sure that you've turned them in in your php.ini file.

In most distros it can be found at /etc/php/php.ini or if your on shared hosting you may have a special one just for your account.

Do a search in the php.ini file and make sure that the extension is enabled.

extension=gd.so (enabled) vs ;extension=gd.so (disabled)

Troubleshooting "The command 'drush.php update' could not be executed."

I have several Drupal 5 Multisite installs. I was able to run "drush update -l www.example.com" on several of them successfully, but a few of the installs failed with "The command 'drush.php update' could not be executed."

Cryptic indeed.

There is a drush patch to provide more helpful error messages (http://drupal.org/node/449090).

but in my case it was just that the Drupal Core "Update Status" module wasn't enabled on the offending sites.

troubleshooting Drush bootstrap on localhost

Troubleshooting the "Drush was not able to start (bootstrap) the Drupal database." when trying to run in on a localhost configuration.

Many thanks to Chris Wells from Redfin Solutions for this troubleshooting tip on getting drush to work in a localhost configuration.

In the settings.php file, try changing

$db_url = 'mysqli://username@localhost/example';
$db_prefix = '';
to
$db_url = 'mysqli://username@127.0.0.1/example';
$db_prefix = '';

comment #12 http://drupal.org/node/502252

Block visibility based on taxonomy term

If you want a particular block, to only show on pages with a specific taxonomy term, drop this snippet into the block visibility field


if ((arg(0) == 'node')) {
$node = node_load(arg(1));
foreach ($node->taxonomy AS $vocab) {
if($vocab->tid == 185){
return true;
}
}
}
return false;

Of course, they're are much more elegant ways to handle this using views/arguments

IE Favicon issues. .htaccess and the Boost Module for Drupal 6

IE Favicon issues, .htaccess and the Boost Module for Drupal 6

I recently spent a significant amount of time tracking down an issue on a client site where the favicon.ico file would display properly on all browser/os combinations with the exception of IE ( all versions).

After checking the usual suspects (corrupted favicon.ico file, proper file size/format, permission settings, etc.) I started to dig a little deeper, trying to think of things that would affect display.

Syndicate content