php

Simple Slideshow for Wordpress

Admittedly I don't know Wordpress very well, so you are welcome to take this with a grain of salt. I wanted a slideshow plugin that could use all existing media plus media that a user uploaded to their blog post landing pages. I did not want to create tags for slide shows etc. I did not want the user to have to deal with gallery vs. upload vs. library vs. stashing images in some other random place.The idea was to be as dead simple but to change the user process as little as possible.

Enter the jQuery. There are lots of great jQuery plugins to do slide shows. I used the jQuery Cycle Plugin. Markup is straight forward- just put a bunch of images into a div and use .cycle(). My approach was to grab all the images in a post, hide them, and add them into the jQuery Cycle div. Not much to it. I used a custom field to enable the slide show if the user wanted it and then they could just add as many images to their post as they liked.

Writing panels integration

I'm working on a project where I need to get some of my custom content into Panels. Having the Panels interface to manage things is obviously a huge boon, but I wanted to do more than create Drupal blocks- I wanted the same kind of integration that modules like Views and CCK are using.

Poking around, I didn't find much information on how to actually write your own Panels integration, so after a few fits and starts, I just started from block.inc as an example and then have abstracted it here.

Leopard Annoyances

1) Having to redo Apache php configuration. Need to turn on the module and re-enable any directory overrides you have
2) MySQL is unhappy. Here are some notes:

#sudo /Library/StartupItems/MySQLCOM/MySQLCOM stop

sudo mkdir /var/mysql/

sudo ln -s /tmp/mysql.sock /var/mysql/mysql.sock

sudo /Library/StartupItems/MySQLCOM/MySQLCOM start