Unfortunately, the ffnet.source.php that code snippet was taken from is in shambles and contains numerous errors. I just posted the fix relevant to the current "trunk" (basically rgibbo's Windows port of erayd's latest script). Even then, I had to fix up the snippet because it had bits and pieces of extraneous code.
By the way, mobileread seems to have changed & # 1 8 7 ; (remove spaces) to ». Try changing it back and see if that fixes things.
Okay, I re-downloaded and reverted back to rgibbo's version and implemented the changes I made. Here's to hoping it works.
http://www.utterlyinsane.org/fflag/ffnet.source.zip
The epub.codec.php snippet probably works, but if you can't study the source code and see where the problem is, I'd just leave the old version be. It's quite possible that the snippet won't work since it was tested with different versions of the scripts compared to what's been uploaded. Besides, the only relevant fix made between this and the version I uploaded a few days ago (in the custom recipe thread) is how it handles crossover fanfics.
Previous behavior for crossover fanfics is to create a new category/subject/tag
Category 1 and Category 2 as its own separate category. With the fix, it will tag the fanfics as being part of each individual category, e.g. it will be tagged as
Category 1 and
Category 2 separately.