Hi Andrew,
Yep no problem - let me know how I can help.
When I turn off the error supression I get:
Fatal error: Cannot redeclare class magpierss in /..snip../plugins/pi.magpie.php on line 0
I couldn’t get the categories to work I’m afraid. Here’s the code I’m using:
{exp:feedgrab url="http://del.icio.us/rss/dodland/dom"
weblog="5"
cat_group="1"
cat_delimiter="SPACE"
cat_field="dc:subject"
title="title"
date="pubDate"
use="link|description"
fields="delicious_url|delicious_body" }
It pulls in the links ok but doesn’t insert any categories.
Would be unbelievable if this worked - you could use a cron with wget to sync pretty much any rss feed with categories.
Still pretty good without categories though!
My mistake withe the parameter name, sorry. They should be category_ not cat_.
Your example would be:
{exp:feedgrab url="http://del.icio.us/rss/dodland/dom"
weblog="5"
category_group="1"
category_delimiter="SPACE"
category_field="dc:subject"
title="title"
date="dc:date"
use="link|description"
fields="delicious_url|delicious_body" }
Note, I think the date parameter should be dc:date for delicious feeds.
I think this should work now.
Thanks for the error message - I think I know what the problem is now (if not the solution yet).
Thanks Andrew
Works like a dream. This is really great.
I’m using a daily cron job to sync my delicious bookmarks each day.
wget -q http://www.pathtoyour/feedgrab_page
They are all categorised and in the db so I can do pretty much anything with them.
If you need any more help debugging let me know.
First time poster and new to EE and I would like to first thank Andrew for the feedgrab plugin it totally saves me time for doing multiple things.
Second I keep seeing posts about Cron jobs and I installed the Expression Engine Cron but I can’t or I should say don’t understand how to implement it. Do I just create a blank template insert the cron plugin on it like this:
{exp:cron minute="*" hour="*" day="*" month="*" plugin="feedgrab"}{/exp:cron}
or do I stick it into the page template like this:
{exp:cron minute="*" hour="*" day="*" month="*" plugin="feedgrab"}
{exp:feedgrab
url="http://ma.gnolia.com/rss/full/groups/SocialMedia"
weblog="11"
title="title"
date="pubDate"
use="link|description|dc:creator|guid"
fields="magnolia_link|magnolia_body|magnolia_founder|feeds_guid"
debug="off"}
{exp:feedgrab
url="http://twitter.com/statuses/user_timeline/776411.rss"
weblog="19"
title="title"
date="pubDate"
use="link|description|guid"
fields="magnolia_link|summary|feeds_guid"
debug="off"}
{exp:feedgrab
url="http://api.flickr.com/services/feeds/photos_public.gne?id=98116400@N00&format=rss_200"
weblog="17"
title="title"
date="dc:date.Taken"
use="media:content@url|media:thumbnail@url|media:text@type|guid|media:title"
fields="full_photo|thumb_photo|summary|feeds_guid|subject"
debug="off"}
{/exp:cron}
I could really use some help.
Thanks, Cesar
Am I missing something? I installed FeedGrab and set up a weblog and a template. I can bring in feeds with no problem and they are imported into the database. But when I try to click on a title under the Edit tab, I get an error message that I have tried to access a weblog that does not exist. Yet, when I go under the Publish tab and choose my feeds weblog, I can publish to it and also edit the entry. I just cannot get into the entries generated by FeedGrab. Is that how it is supposed to work?
Hi wondermonkey, I’m keen to find what’s wrong here (although I’m a bit snowed under at the moment, so excuse me if I’m slow to respond). Andrew
Hey Andrew, I did a bit of fiddling with the plugin code this morning and figured out that it’s definitely the declaration of the MagpieRSS class that causes the Plugin Manager to break. I tested all the rest of the code and it’s fine. If I remove everything in the MagpieRSS class (but not the class itself) I get no Plugin Manager, but as soon as I remove the
class MagpieRSS {
it comes back.
Since Magpie is already installed, is there some way to just import it instead of replicating it in FeedGrab?
It should be fixed in the download below - to make the parameter name a bit more consistent I’ve renamed it author rather than author_id.
So I was testing it out this morning and now it’s gone and done something real bad I think.
I imported a couple blog feeds and tried the parameter author=”author” because “author” is one of the xml items right? It imported them but the entries aren’t coming up on the Edit page so I can’t access them. There’s one entry that appeared in the Recent Entries list and when I check the Author of the entry it’s blank.
So two things I guess: how does the author parameter work and any ideas on fixing this? Since I can’t access the entries from the CP does that mean I have to go hunting through phpmyadmin?
Also, does the plugin grab tags from the feed’s title, link, description etc that aren’t items (about the feed and source, not the entries)?
UPDATE: I fixed it by running an UPDATE query to set author_id=’1’ where author_id=” and now I can access the entries in the Edit panel of CP. Above question about how to use ‘author’ remains… 😉
UPDATE II: After more testing I’m still unable to pull content from Atom feeds such as this one. The tag/item is called “content” but I end up with the word “Array” in my entry’s content field instead of the real content from the feed.
I’m not sure what is going on, but let me explain my situation.
I was happily running FeedGrab v .61 (first revision after caching issue was solved) to grab entries from a last.fm rss feed and import the entries into my blog to be displayed later. This worked well until I noticed that my ee site wasn’t updating properly. I checked the last.fm feed (which was updating properly), made sure my cron job was running properly and narrowed the problem down to the fact that feedgrab wasn’t properly grabbing entries.
I upgraded to FeedGrab .7 (which just borked my plugins CP), and now my feed is updating properly but with some issues:
On the actual page that calls the feedgrab template, I am getting an error when using the refresh=”1” parameter. The entries still load, but the error wasnt there in v .61
Using Feedgrab .7, my track entries have a ? mark where the long dash used to be. This wasn’t an issue with .61. Tracks look like:
Fetching: http://ws.audioscrobbler.com/1.0/user/DigiFiend/recenttracks.rss
Checking: AC/DC ? Ride On
Checking: AC/DC ? Ain't No Fun (Waiting Round to Be a Millionaire)
Checking: AC/DC ? There's Gonna Be Some Rockin'
Checking: AC/DC ? Problem Child
Checking: AC/DC ? Rocker
Checking: AC/DC ? Big Balls
Checking: AC/DC ? Love at First Feel
Checking: AC/DC ? Dirty Deeds Done Dirt Cheap
Checking: Stereo MC's ? Breeze
Checking: Stereo MC's ? We Belong in This World Together
Any suggestions on how to renable the plugin manager and more importantly, how to get feedgrab .7 to recognize the “long dash”?
Version 7 of feedgrab introduced an updated version of the RSS/ATOM reading libray magpie. This allowed the plugin to do have some new, useful (to me anyway) features, like being able to access attributes of elements (eg, <element url=”http://url.com/” >).
It does seem as though the new magpie code does not handle character encodings as successfully as the previous version. I’ve been getting the ‘?’ characters replacing some characters too, typically quotes and dashes.
If you don’t need the new features, I’d suggest going back to v0.61 for now, until I can fix it.
…it’s definitely the declaration of the MagpieRSS class that causes the Plugin Manager to break. Since Magpie is already installed, is there some way to just import it instead of replicating it in FeedGrab?
Unfortunately, the new version of feedgrab uses a newer version of the MagpieRSS class.
Feedgrab actually tries not to redeclare the class in the plugin manager - the problem seems to exist when the Feedgrab plugin is called first, and Magpie redeclares it.
I’ve an idea of how to fix this - I’ll see if I can find time to experiment this week.
Version 7 of feedgrab introduced an updated version of the RSS/ATOM reading libray magpie. This allowed the plugin to do have some new, useful (to me anyway) features, like being able to access attributes of elements (eg, <element url=”http://url.com/” >).
Andrew, would it be possible to do a how-to on this feature? I don’t think it’s been mentioned before and I’ve noticed more and more atom feeds use these attributes instead of normal XML.
Also, what is the semantics for the author/author_id now?
The use of attributes was mentioned in this post. eg, to access the url attriubute of the media: content element of a flickr feed:
<media:content url="http://farm1.static.flickr.com/116/301933412_fad89245a8_o.jpg"
type="image/jpeg"
height="1200"
width="1600">
you would use:
media:content@url
The author field does not take an input value from the feed. It only allows you to hard-code its value to one of the EE authors that you have set up (by id number, not name).
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.