Closed (outdated)
Project:
Feeds
Version:
6.x-1.0-alpha15
Component:
Code
Priority:
Minor
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
22 May 2010 at 14:35 UTC
Updated:
4 Mar 2016 at 21:47 UTC
Jump to comment: Most recent
Comments
Comment #1
DanielR commentedI've made a bit of progress. It seems the best way to use feed item inheritance, rather than mapping.
In FeedsNodeProcessor.inc, function getInheritors(), I added:
And then I added the callback function:
This fails with an unusual error message, because I'm using $item_node->field_feed. If I use something else like $item_node->title, it's OK. Can anyone suggest how I might poke the value into a CCK field? Sorry, I'm a total newbie. The error message is below:
An error occurred. /batch?id=21&op=do <br /> <b>Fatal error</b>: Cannot unset string offsets in <b>/var/www/paperfeed.org/sites/all/modules/cck/content.module</b> on line <b>1248</b><br />(Yes, the html tags show up unrendered)
Comment #2
DanielR commentedChanged the name of the issue, to avoid misleading mention of mapping.
Comment #3
DanielR commentedSome further progress. The following syntax works for setting the CCK field (see previous comment):
$item_node->field_feed[0]['value'] = $feed_node->title;Please consider this issue closed as far as I'm concerned.
Comment #4
DanielR commentedI'd like to reopen this issue - I still feel it adds a lot of value to the module if feed items can inherit the title of the feed they come from. I think I was incorrect in closing it earlier when I found a workaround.
Sorry if I have overstepped the bounds of etiquette here. I'm very new to drupal.org.
Comment #5
alex_b commentedThis feature makes sense. I suggest using the mapping API for implementing it. The mapping API is actually designed for item to item mapping, so OTOH, I can't tell whether using feed properties themselves would lead to very nasty code.
Comment #6
alex_b commentedHm - on a second thought, some of the functionality in #632920: Inherit properties from parent feed node (taxonomy, author, OG, language) could be implemented as mapping sources, too. Just a thought.
Comment #7
kenorb commentedClosed because Drupal 6 is no longer supported. If the issue verifiably applies to later versions, please reopen with details and update the version.