Doing Things Wrong

More Bad Programming

Just when I finished all the work on the slideshows, I found a serious flaw in the Nivo Slider plugin. If you put multiple slideshows on a page, each one clobbers the one before, and you only get the last one. I guess they never tested that.

But why would you put multiple slideshows on a page? Actually with a database-backed CMS like WordPress, it can happen very easily, even if no page in the website actually has more than one slideshow on it. Like this or this.

So I spent some time looking at the code, found the right place, and changed a few lines. Now my sliders happily coexist. I tried to contact the owners of the code to give them the fix. We'll see.

I've always been really good at "maintenance programming": Take someone else's code, that has probably been abandoned for years, find the problem, and fix it, preferably without making new problems! Once, in college, I was given an operating system assignment to add some new functionality to a Linux kernel. It was supposed to take a whole semester. I studied the code, found the hook for the new code to go, and found an existing function that did almost what was asked. Then it was just copy-paste-edit, and it worked perfectly. A few days after I was given the assignment, I went back to the prof and said "Here, I'm done." And it was a really elegant solution too, no one could complain about it. That prof was pissed that I didn't spend three months slaving over his assignment, but I got an A.

In fixing this plugin, I made no attempt to understand how the whole thing works. There is no need, the problem is very specific, and the rest of it works fine. I searched though php files until I found where the slideshow is actually generated, and made minimal changes just there, that have no effect anywhere else. That is what maintenance programming is all about.

So anyway, I salvaged all my work in Nivo Slider. I was not looking forward to re-doing everything in some other slideshow, just to find out that one is broken too !!! Now I want to figure out how to stop the content below the slideshows from wiggling when the slides are not all exactly the same size. I did that by making most of the slideshows manual instead of automatic, so they only wiggle when you poke at them.

Still really glad to be rid of MetaSlider and its mountain of garbage.

Update:

Exactly as I feared, their response was ... complete disinterest in a 'retired' product. They have basically abandoned the project, and do not want to spend even ten minutes fixing a serious flaw. This is why I distrust WordPress plugins. You just don't know what you're getting. I will try to press the issue.

Update:

Confirmed, they have zero interest in fixing this, even if I give the whole thing to them for free. This is another example of why it is so dangerous to use free software. One day it will break, and you'll be out of luck. My guess is the original developer left, and they don't have anyone who can deal with the orphaned code ( although I did easily ! ) I would be very leery of buying anything from ThemeIsle.com.

I should change the title of this post to More Bad Programming and Support.


Audiovox Gibson-style Bass
Audiovox 736 Replica Bass
Audiovox Gibson-style Guitar
Audiovox Danelectro-style Bass
Audiovox Fretless Bass
Audiovox Electric Upright Bass
Audiovox Strat-style Guitar
Audiovox 12-string Guitar
Audiovox Ukulele Bass
Audiovox Mandolin
BC Rich "Osprey" Bass
Brownsville Violin Bass
Cowbell Bass
Danelectro Pro-1 Bass
Danelectro "Super-63" Guitar
Danelectro Silvertone 1457 Rescue Guitar
Danelectro Longhorn Guitar
Danelectro Silvertone U-1 Guitar
Danelectro Companion Guitar
Danelectro Silvertone 1443 Bass
Danelectro '67 Hornet Guitar
Fender Jazzmaster Bass 1
Fender Jazzmaster Bass 2
Fender Jazzmaster Bass 3
Fender Stratocaster Bass 1
Fender Stratocaster Bass 2
Fender Stratocaster Micro Bass 1
Fender Stratocaster Micro Bass 2
Fender Stratocaster Fretless Bass
Fender Stratocaster Bass VI
Fender Stratocaster Bass IV
Fender Stratocaster 12-string Guitar
Fender Stratocaster Uke Bass
Fender Squier Stratocaster Guitar
Fender Telecaster Bass
SX Precision Bass
Gibson Fenderbird Bass 1
Gibson Fenderbird Bass 2
Gibson Reverse Fenderbird Bass
Kubicki Bass
Schwinn Stingray Bass
Mosrite Bass
Rickenbacker 325 Guitar
Rickenbacker 325 Bass 1
Rickenbacker 325 Bass 2
Rickenbacker 325 Bass 3
Rickenbacker 4001 Bass 1
Samick SG450 Guitar
Danelectro Pro-1 Guitar
Danelectro Silvertone 1448 Guitar
Danelectro '63 Guitar
Danelectro Silvertone 1457 Guitar
Harmony H617 Bobkat
Danelectro Silvertone 1450 Guitar
Harmony Silvertone 1478
Danelectro Silvertone 1472 Amplifier
Danelectro Longhorn Bass

I've been working on another website lately, but it uses the same code base as this one, so all of the improvements get carried over. The latest thing I've done is a complete rework of the slideshow plugin.

First, I stripped out a lot of fat - unused features, ugly themes, 'call-homes', etc. I hardwired some stupid options, added some new ones, fixed a few major problems, and made it much faster. Finally, I put the whole thing through the wringer and got rid of anything that was not strictly needed, everywhere - PHP, JS, CSS. My version is less than half the size of the original.

The result is a yuge improvement, both on the front end, and especially on the back end: