Archive for April, 2010

Drain Hole template: Listing the contents of a hole with nested file structure, v.1.1

April 29th, 2010 Comments off

Two days ago, I published a template for Drain Hole, that displays the nested structure of a hole. That was version 1.0. Yesterday I realized that I had made a simple mistake, that resulted in an annoying bug. It was impossible to display more than one hole on the same page. The fix was simple enough, so I have now released a version 1.1 of the template, without that particular bug.

Categories: WordPress Tags:

Drain Hole template: Listing the contents of a hole with nested file structure, v.1.0

April 27th, 2010 Comments off

Drain holes normal list template only lists the files in the hole without showing the nested file structure. It is as if all files are on the same level. I wanted to list files such that the file structure is visible, somewhat the way you can view the structure in the left pane of Windows Explorer. Therefore, I have written a template for Drain Hole that reveals the nested structure.

Categories: WordPress Tags:

WordPress twist: Combining NextGen and DrainHole

April 11th, 2010 Comments off

So, my WordPress Hack that ended up as a simple plugin which needed a few tweaks to the NextGen plugin turned out to be overkill. No surprise! The real problem was that the .htaccess file that Drain Hole suggested assumed that the Apache module mod_rewrite was around. Turned out it’s not. So all I needed to do was to provide another .htaccess file.

See also:

Categories: WordPress Tags:

WordPress hack: Combining NextGen and DrainHole

April 7th, 2010 Comments off

NextGen is a really well thought through plugin handling image galleries. It has one obvious drawback; It does not allow me to limit the access to the images themselves. Granted, you can limit the access to pages displaying the images using WordPress user settings, but not the images. Drain Hole is another well thought through plugin that among other things allows you to limit access based on wordpress user status. It does a lot more if you want it to, but I needed access limitation.

Good, then we combine them. Just install them and we’re off. Yeah, right! You could wish it would be that simple. It’s not. Their file placement and URLs do not fit, unless we adjust the way NextGen generates URLs. Therefore I have produced a dead simple plugin that, combined with adjustments to a few of the files in the NextGen plugin, does the trick. For details, go to

Categories: WordPress Tags: