Adding RefTagger to a Drupal Site

LogoDrupal is popular open source Content Management System (CMS) software. Many churches and ministries use it.

A few days ago I got a request from an individual who wants to add RefTagger to his Drupal site but isn’t sure how to get it set up, so I thought I’d provide a quick tutorial.

Unfortunately, Drupal doesn’t allow you to edit the code of your themes from the admin panel, at least not that I can see. But if you have access to your site’s files via FTP, you can add RefTagger very easily.

Here are the simple steps you need to follow:

  1. Use an FTP program to navigate to the folder where you installed Drupal.
  2. Open the “themes” subfolder, and then open the folder for the specific theme you are using. (The default theme is Minneli, which is a subtheme of Garland, so you’ll find the file in the “garland” folder.)
  3. Locate the page.tpl.php file, and save a local copy (and a backup copy too).
  4. Open the file in Dreamweaver, WordPad, or your favorite code editor.
  5. Scroll to the bottom and paste the customizable RefTagger code before the </body> tag.
  6. Save the file and upload it back to your server.

That’s it. RefTagger is now transforming the content of your Drupal site!

If you’re using RefTagger on your Drupal site, please let us know. We’d love to see how you are putting it to use.

For help with other sites, see the tutorials section on the RefTagger page.


  1. NO! There is a much easier method. Drupal is so powerful with it’s BLOCKS concept.

    1. Log in as the administrator.
    2. Navigate to admin>Site building>blocks
    3. Click on ADD block or simply type this in your address bar:
    4. Paste the reftagger code into a block and name it something ingenious like “Reftagger”.
    5. Change the “input format” to full HTML and save the block.
    6. Then activate it as a footer block, it will remain invisible but will immediately tag every reference on your site!
      Don’t mess with the template’s unless you have too, keep it simple and use Drupal the easy way. :-)
  2. Thanks, Thomas. That’s good to know. However, I’m not sure your way is much easier than mine. Notice that we both have 6 steps! :)
    Do you use Drupal for your site?

  3. Yes powered by Drupal and happy about it! :-)
    The beauty of using a block as opposed to hacking the source (page.tpl.php) is that it’s all done in a web front end.
    Moreover if you do an upgrade (like apply a security update) to your site the hand edited code get’s overwritten and thus lost. But the block stays until you disable it.
    That is one of the purposes of blocks.

  4. Thanks, Thomas. Good points. Glad to know of a better method.

  5. We’re working on a Drupal version of SharperIron for future release. So far, RefTag doesn’t seem to be working. To be precise, we’re using vbDrupal (a fork of Drupal) but that shouldn’t matter. We’re also on ver. 5.
    I put the code in page.tpl.php right before body. But I’m not seeing any changes in the content.
    Will send email w/details, Phil, and we can work it out.

  6. Working now at SI dev site using Phil’s method. Looks great. Haven’t tried Thomas’ method yet.
    By the way, we’re using vbDrupal ( a fork from Drupal so I can verify that the template edit method words in vbDrupal 5.x.
    We also have vBulletin linked in (that’s what vbDrupal does), but I haven’t set up RefTagger in the forum yet.

  7. I’ve worked with Drupal for years, and the way Thomas specifies is definitely the recommend way for Drupal! Blocks are specifically intended for a purpose just like RefTagger.

  8. Actually… the best way to implement RefTagger in Drupal, is with a Drupal module. At the link below you can find Drupal 5 and 6 modules for RefTagger, that allow you to configure RefTagger all within Drupal without having to mess with templates, blocks or any code.

  9. We have it up and running on our development site now using the Module method, 5.x version. We can verify also that it works for vbDrupal 5.x.

  10. I think this module is fantastic and would love to use. The one problem is that my site in Portuguese. Any chance of adding a Portuguese translation? I know some changes would need to be made in the file to account for different spellings and changes from the English to the Portuguese. I would be willing to help in any way.
    Thanks and God Bless

  11. Great tool! Very useful. I like how it even provides a choice of translations to quote from.