View Single Post
Old 04-20-2009, 11:21 AM   #101
ilovejedd
hopeless n00b
ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.ilovejedd ought to be getting tired of karma fortunes by now.
 
ilovejedd's Avatar
 
Posts: 5,110
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
Quote:
Originally Posted by Mnementh View Post
Hmmm don't know what I've broken but I now can't produce either an epub file using php cli or even an html version using print.php.

I've tried both versions of epub.codec.php (the one ilovejedd posted as an attachment and the code listing in her post above), in fact I've actually tried every version i can find posted and also amalgamations of them all (admittedly my understanding of php is extremely limited so that probably wasn't a good idea...), I've also tried every version of ffnet.source.php and various amalgamations I can find again to no avail.
It wasn't something you broke. FanFiction.Net just changed things around Friday and then again, last night. I haven't had time to upload the fixed version (was drinking at my friend's house from Sat 8:30pm until 5am yesterday, woke up 8:30am to go visit another friend, finally went home 10:30am, slept most of the day, had dinner, tried to read some fanfics on iphone which obviously didn't work, fixed my local copy of ffnet.source.php and finally went to sleep).

By the way, the code posted above is for ffnet.source.php (post #97). I guess I should've specified that. I haven't made any changes to epub.codec.php since FanFiction.Net did the crossover changes (basically changed to reflect both categories in the subject/tag).

In future, though, I suggest you keep whatever source code you have (epub.codec.php, etc) in case something's not functioning. Chances are, the fault lies within ffnet.source.php because FanFiction.Net changed its site layout or something and not because of any of the other modules.

If you're impatient like me, you might want to try your hand at fixing ffnet.source.php, specifically the ffnet_get_meta($page) function since that's the one that usually gets broken when there are changes to the site. I think the commenting should be sufficient to navigate the source code. The algorithm to determine the various metadata is just based on regular expressions so I suggest you read up on that. I've found the following to be a valuable resource:
http://php.net/manual/en/book.pcre.php
ilovejedd is offline   Reply With Quote