Part of the EllisLab Network
   
 
rss problem
Posted: 08 July 2008 03:53 PM   [ Ignore ]  
Grad Student
Rank
Total Posts:  60
Joined  05-28-2007

i’m trying to load my del.icio.us feed into my blog and was checking out the library in the wiki section, however i keep coming up with this error

Parse error: syntax error, unexpected ‘;’, expecting T_PAAMAYIM_NEKUDOTAYIM in C:\xampplite\htdocs\ci\system\libraries\RSSParser.php on line 43


i took straight from the wiki, so wondering where i must have gone wrong, anyone point me in the right direction?

controller

$this->load->library('RSSParser', array('url' => 'http://test/rss/rss''life' => 2));
        
$rss $this->rssparser->getFeed(10); 

view

<?php foreach ($rss as $item) : ?>
    
<li><?=$item['title']?></li>

<?php endforeach; ?> 
Profile
 
 
Posted: 09 July 2008 07:36 AM   [ Ignore ]   [ # 1 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  550
Joined  10-18-2006

The error is a sintax error inside the RSSParser.php, so the code you put is not the problem…
By the error I’m guessing you are running PHP 4 and the library requires PHP 5… if that’s not it, copy the line 43 of the RSSParser.php file.

 Signature 

Once in a while I remember I use Twitter

Profile
 
 
Posted: 09 July 2008 09:27 AM   [ Ignore ]   [ # 2 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  727
Joined  08-03-2006

It says that it is expecting a double colon.

I wonder why it is not called T_DOUBLE_COLON…

 Signature 

RapidDataMapper: My new ORM, is now released!

IgnitedRecord: Old ORM

MPTtree: A model to handle trees in a database.

YAYParser - Yet Another YAML Parser

Profile
 
 
Posted: 09 July 2008 04:00 PM   [ Ignore ]   [ # 3 ]  
Grad Student
Rank
Total Posts:  60
Joined  05-28-2007

i tried the double colon but couldn’t get the rssparser corrected. I am running php5.

i tried to remove the semi-colon but it then seemed to work, however not feed the info from the feed. more like some broken english nonsense… strange.

any other ideas

Profile
 
 
Posted: 09 July 2008 08:29 PM   [ Ignore ]   [ # 4 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  550
Joined  10-18-2006

Can you paste the code?

 Signature 

Once in a while I remember I use Twitter

Profile
 
 
Posted: 17 September 2008 09:03 AM   [ Ignore ]   [ # 5 ]  
Grad Student
Rank
Total Posts:  60
Joined  05-28-2007

thought i would bring this one back up, sorry for the delay but other duties were called upon.

I started building a new personal site which i’m looking to integrate my feeds from lastfm and delicious, however I seem to get a blank page.

when i print_r($rss);

it is a blank array? Can anyone have a look at my code and see if i’m missing something?

controller;

      
$this->load->library('RSSParser', array('url' => 'http://feeds.delicious.com/rss/theblackcat''life' => 2));
      
//Get six items from the feed
      
$data['rss'$this->rssparser->getFeed(10);
    
$this->load->view('test_view'$data);


view;

foreach (
$rss as $item) :

    echo 
$item['title'];
    

  endforeach; 
Profile
 
 
Posted: 17 September 2008 09:04 AM   [ Ignore ]   [ # 6 ]  
Grad Student
Rank
Total Posts:  60
Joined  05-28-2007

i should note i’m using the rssparser from the wiki

Profile