diff options
author | Andrew Dolgov <[email protected]> | 2014-02-14 20:08:06 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2014-02-14 20:08:06 +0300 |
commit | 0c4c0ab463dd8e0c8ef3ea745496097cba340e6c (patch) | |
tree | 20dd43515121e95fdabd919d847ffdcefe195a25 | |
parent | abe24e397783ccff66f83536cb4ea46c7bb68f5f (diff) | |
parent | 3df1a8b85791bbf6be5754e372eb1e7ae8e02326 (diff) |
Merge pull request #346 from kythyria/comicsfix
Okay, let's fix just the bits of Penny Arcade that actually need fixing
-rw-r--r-- | plugins/af_comics/init.php | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/plugins/af_comics/init.php b/plugins/af_comics/init.php index 993ddb7cd..88d537814 100644 --- a/plugins/af_comics/init.php +++ b/plugins/af_comics/init.php @@ -240,7 +240,19 @@ class Af_Comics extends Plugin { $basenode = $entry; } - $uninteresting = $xpath->query('(//div[@class="heading"])'); + $meta = $xpath->query('(//div[@class="meta"])')->item(0); + if ($meta->parentNode) { $meta->parentNode->removeChild($meta); } + + $header = $xpath->query('(//div[@class="postBody"]/h2)')->item(0); + if ($header->parentNode) { $header->parentNode->removeChild($header); } + + $header = $xpath->query('(//div[@class="postBody"]/div[@class="comicPost"])')->item(0); + if ($header->parentNode) { $header->parentNode->removeChild($header); } + + $avatar = $xpath->query('(//div[@class="avatar"]//img)')->item(0); + $basenode->insertBefore($avatar, $basenode->firstChild); + + $uninteresting = $xpath->query('(//div[@class="avatar"])'); foreach ($uninteresting as $i) { $i->parentNode->removeChild($i); } |