diff --git a/code/BlogTree.php b/code/BlogTree.php index 94e85de..c977ddc 100644 --- a/code/BlogTree.php +++ b/code/BlogTree.php @@ -38,7 +38,7 @@ class BlogTree extends Page { * - Otherwise, try and find a 'top-level' BlogTree */ static function current() { - $page = Director::currentPage(); + $page = Director::get_current_page(); // If we _are_ a BlogTree, use us if ($page instanceof BlogTree) return $page; diff --git a/code/RSSWidget.php b/code/RSSWidget.php index 99d60c0..6578411 100644 --- a/code/RSSWidget.php +++ b/code/RSSWidget.php @@ -60,9 +60,9 @@ class RSSWidget extends Widget { include_once(Director::getAbsFile(SAPPHIRE_DIR . '/thirdparty/simplepie/SimplePie.php')); $t1 = microtime(true); - $this->feed = new SimplePie($this->AbsoluteRssUrl, TEMP_FOLDER); - $this->feed->init(); - if($items = $this->feed->get_items(0, $this->NumberToShow)) { + $feed = new SimplePie($this->AbsoluteRssUrl, TEMP_FOLDER); + $feed->init(); + if($items = $feed->get_items(0, $this->NumberToShow)) { foreach($items as $item) { // Cast the Date @@ -84,4 +84,4 @@ class RSSWidget extends Widget { } } -?> \ No newline at end of file +?>