drupal planet

Just Created: New Drupal Module "Gallery Archive"

Gallery Archive Project Page on drupal.org

I just created my second open source software project (for Drupal), Gallery Archive. This is the first Drupal module I've created, and I'm excited to be able to dive into many more APIs I've not yet interacted with. Drupal has been a great adventure in my life, and I'm finally getting good enough with 'drupal-fu' (like kung-fu, but in Drupal-speak) that I can come up with solutions to my own problems :)

Allowing anonymous IP-based access to content with Boost, subscription model

On the St. Louis Review website (case study here), which offers much of its content based on a subscription model (you must be a subscriber to access the 'premium' content), we wanted to allow those inside our network access to nodes that were marked 'subscribers-only', without having to log in to the website and maintain a user account. Here's how we did it:

1 - Modification of Custom Subscriber Access Code

Our site uses hook_nodeapi() to limit access to 'premium' or 'subscribers-only' content. We simply added in a check to see if users were coming from a certain IP address (the IP address for our corporate network):

Druplicon Golf Ball (DrupliGolf)

After having seen DrupliBacon and DrupliCake (there are other great adaptations of the Druplicon as well!), I decided I wanted to get some creative juices flowing this weekend. I present, DrupliGolf!

DrupliGolf - Druplicon on a Golf Ball

Drupligolf is the result of a round of golf, an addiction to Drupal, and a love for the best OSS mascot in existence. (The latter reason will definitely strike a chord with anybody who's shared a drink with the Druplicon in #drupal... and actually drank).

Post Photos/Images to Your Drupal Site from the iPad

Now that I have effectively replaced my laptop with an iPad, I need an easy/quick way to post a photo or two from my iPad to my blog. I use Photogene as a simple Photoshop replacement on the iPad (it actually works pretty well, for being limited to 256 MB of RAM and a 1024x768 display).

I originally tried using an FTP program to transfer the file to my website, into a drop box folder I created, but FTPWrite, one of the very few FTP apps for the iPad, doesn't support uploading from my photo library. Not wanting to pay for any more weak FTP editors until Coda or something equivalent is released for the iPad, I decided to go about this task in a rather unorthodox way. Here's how I post photos to my Drupal site from my iPad:


On your iPad:

Druplicon - Stark (image for theme)

Below is the full-size image mockup I made for webchick to highlight the awesomeness of Drupal's (relatively) new stark theme, as seen in Drupal 7. You can download Stark for Drupal 6 as well, but it will be a nice way to quickly expose the underpinnings of Drupal's core HTML output.

Stark - Druplicon in Overcoat

(click on the image to view a larger copy)

I'll be working on at least one CSS-only theme for Drupal 7 over the next couple of months, and will hopefully release it to drupal.org by summertime. The transition from 6->7 is going to be awesome for themers!

Allowing Organic Groups Administrators the Ability to Unpublish/Publish and Schedule Content

One requirement of the Archdiocese of St. Louis' website is that group administrators are able to publish and unpublish the content inside their groups, and they should also be able to schedule posts for automated publishing and unpublishing at a later time.

To do this, I used the following modules:

After enabling these modules, I spent a while in the Permissions page, and also created a new user role, "administer nodes." Ironically, I didn't assign the 'administer nodes' permission to this role, because doing so causes a huge mess ('administer nodes' gives waaay too much power to anyone except the site admin—it's best to leave that beast unchecked in most cases).