katrin's blog

Finding most popular email providers your users use

<intro-rant>So you're running a Drupal site. The site's performance is decent and there's nothing really to complain about except at some point your marketing team or marketing person comes to you and you end up having a conversation like this:

Them: You know we really love the share widget thingie we got on the site and all the stats that it comes with but which of these services do our people really use?

You: ?

Them: We would like them to log in using those services instead of having to create local accounts. You know, make it easier. I hear simple sign on is the way to go these days!

You: Sure, there are a few modules out there that we can try out. There's this thing called Janrain Engage for example....

To flag or not to flag

Screen shot 2010-07-27 at 12.25.30 PMDrupal's Flag module comes in handy in various situations. It does however have one major drawback for some use cases - there is no way to clear all flags of a certain content item. Imagine the following use case for example - users are allowed to mark certain comments on the website as abusive or not fit for the content.

How to convert live Domain Acces site to a local copy

Let's face it - sometimes you need a copy of a site running Domain Access on your local machine. It does require some tweaking to get it up and running since you need at minimum to change your hostnames. I keep a query around for each local site db to do this for me (automation is your best friend after all). It's plain and simple if you are using subdomains but it can easily be adjusted to full domain names:

UPDATE domain set subdomain = replace(subdomain,'thebeehive.org', 'beehive.trunk');

This query will replace all thebeehive.org occurrances in domain table with beehive.trunk.

And for the heck of it make sure sessions and watchdog tables are empty before you start:
TRUNCATE sessions;
TRUNCATE watchdog;

Pages