At The Radcliffe Arms

Another coffee? Sure

Random

Another coffee?

Image
red

I like red

Graphic, Random

Favourite colour

Image
Rants, Web

Gallery3 + WordPress 3.2.1 = FFFFFFFUUUU

Gallery3+WP=FFFFUUUU

I know that a WordPress on top of Nginx isn’t all unique but unfamiliar to me, but this fiddling was ridiculous!

I have set up a Gallery3 install (since they’ve stopped maintenance of Gallery2 I believed that I should also use the most active and stable version). Oh boy, was that awful: I realized late that they have intended to depend on Javascript; signs of a design approach I am strongly against. Later, after much pain of creating a custom theme for my gallery (deserving it’s own rant mainly containing one four-letter word rhyming with ‘truck’), I wanted to be able to import images from this to WordPress using the Gallery3 Picker plugin. Given that it had rave reviews and a good method of integrating with WordPress, I thought the install would be painless. I guess anything mainstream written in PHP is going to be anything _but_..

So, after much frustrating FFFFFFFUUUUUUUUUU away from sharp pointy objects and a large crowd of random victims, I found this (gallery3-picker/picker.php line 320):

320
if ($http_status == 302)

Now, the plugin tries something smart: it first tries the /index.php then if that fails retries with the plain URL – assuming that it does SEO rewrites.

If you took a moment to examine my Nginx setup you may have noticed this line:

location ~ \.php$ {
        try_files $uri =404;

.. So if it cannot find a file, it throws a 404 – naturally. Delving into it, the final URL the plugin was after adds a /path/to/rest at the end: so the actual URL hit for me would return 404 at the first pass, not to retry the next.

I have my tweak at least:

320
if ($http_status == 404 || $http_status == 302)

Geez, it’s as if you are hungry but the only option is a greasy burger at a fast-food joint you wanted to avoid. Then you discover that your patty is underdone and they demand that you use their unintuitive stove to cook it yourself. Hmmm.. this food talk makes me slightly less angry and more hungry – time for lunch!

Standard
Random, Rants

Some people insist that they’re city folk, which I fail to understand. Who the hell likes to be in a constantly noisy, crowded environment – it causes (di)stress needlessly.

The following is just a small subset of reasons why I like it here in this little market town:

Link
Web

Twenty Eleven Post Formats – What Are They and Why Should I Care? A great post explaining what the available post types are and what they do in the Twenty Eleven theme (which is the ‘parent’ of this site’s theme).

In this theme, I’ve tweaked the ‘link’ type behaviour after I surprisingly found out that the ephemera widget takes the first link in ‘link’ types. It seems to favour single links-per-posts only, and I tend to get a little wordy (like this ‘link’ post.)

Link
Android, Random, Rants

Java is like a variant of the game of Tetris in which none of the pieces can fill gaps created by the other pieces, so all you can do is pile them up endlessly.

Steve Yegge (2007, Codes Worst Enemy)

From cat -v

Installing a fresh Eclipse, then running into getting the Android SDK to work with it – another activity that wants me to gouge my eyes out. Goddamn, this is why I really like vim.

I really wish we can break up, Java

Quote