Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

check for link_html tags as well (before id) to make blogspot atom p…

…osts parse correctly
  • Loading branch information...
commit 540086ec01ba2ceef3e5f52f27fa43b10d8f15d8 1 parent c5c2217
@chregu authored
Showing with 8 additions and 1 deletion.
  1. +8 −1 libs/aggregator.php
View
9 libs/aggregator.php
@@ -57,7 +57,6 @@ function aggregateAllBlogs($id = null) {
}
}
- var_dump($feed->channel);
if ($feed->channel['link_html']) {
$feed->channel['link'] = $feed->channel['link_html'];
} else {
@@ -109,9 +108,17 @@ function aggregateAllBlogs($id = null) {
if (!isset($item['link']) && isset($item['link_'])) {
$item['link'] = $item['link_'];
}
+ if (!isset($item['link']) && isset($item['link_html'])) {
+ $item['link'] = $item['link_html'];
+ }
if (!isset($item['link']) && isset($item['id'])) {
$item['link'] = $item['id'];
}
+
+ if (strpos($item['link'],"http") !== 0) {
+ print "ERROR, item link " . $item['link'] . " doesn't start with http\n";
+ continue;
+ }
if (!isset($item['content']['encoded']) && isset($item['atom_content'])) {
$item['content']['encoded'] = $item['atom_content'];
}
Please sign in to comment.
Something went wrong with that request. Please try again.