I'm trying to add a line showing the last updated time for my RSS aggregator feed block (essentially the checked
timestamp field from the aggregator_feed
in a formatted manner).
I'm not able to find a preprocess function that lets me get this value.. the closest i got was implementing
function mm_theme2_aggregator_block_item($item, $feed = 0) {
if($item->fid) {
$fetch_modified_time = "SELECT `checked` FROM {aggregator_feed} WHERE `fid` = %d";
$feed_last_modified_time = db_result(db_query($fetch_modified_time, $item->fid));
}
$last_modified = 'Last Modified time is ' . date('D M d h:i:s T Y', $feed_last_modified_time);
$output .= '<a class="rssContent" href="'. check_url($item->link) .'" target="_blank">'. check_plain($item->title) ."</a>\n";
return $output;
}
where i'm not sure how to pass on this value to my $block or to $variables. Also this method iterates for each feed item and it'd be unwise to get the same value executed multiple times.
I'm pretty certain there's a drupal based way to get what i desire and am missing something.
Any help/support on this would be really helpful.
Thanks in advance