I couldn't get your module to format media:thumbnail & media:content properly. By making the changes outlined in this patch (simply commenting out some preprocess functions, I was able to get it to work.

Patch coming...

CommentFileSizeAuthor
#1 1559334_views_rss_media_fix.patch1.09 KBdavidseth

Comments

davidseth’s picture

StatusFileSize
new1.09 KB
maciej.zgadzaj’s picture

Assigned: Unassigned » maciej.zgadzaj
Status: Needs review » Needs work

Eh, this one is much more tricky. Essentially these preprocess functions do not work properly now as they were written for the old way of building the feed by Views RSS module. Now that is uses format_xml_elements() all preprocess functions need to be rewritten. And then:
- removing preprocess for <media:thumbnail> is fine,
- preprocess for <media:content> cannot really be removed, as then we're loosing optional <media:group> element - it needs to be refactored instead,
- all other current preprocess functions need to be refactored as well (excluding views_rss_htmlspecialchars which just needs to be removed),
- I need a good solution for <media:category> element - formatter would be the best here, but as taxonomy fields in Views do not use formatters, I would need something similar to views_rss_handler_field_term_node_tid class from Views RSS module (actually almost identical), but then don't like the idea of extending that class again... need to think it through.

davidseth’s picture

Thanks for the update... I will keep an eye on this.

davidseth’s picture

Just a quick check in to see if you had any more thoughts on the matter.

Regards,

David

Chris Charlton’s picture

Checking in on this. Any more code thoughts to review or are we just missing a good set of patches at this point?

maciej.zgadzaj’s picture

I've started working on this quite a some time ago, but then had other work coming and didn't have time to finish it yet I'm afraid. Should get back to it soon though.

Chris Charlton’s picture

Is there anything I can help with to move this along?
I am assigned to a project currently where this module is quite critical. LMK

maciej.zgadzaj’s picture

Status: Needs work » Fixed

You might want to check 7.x-1.x-temporary-code branch - all media: elements should be working now, apart from media:category, which for the moment is disabled. I will re-enable it once I have an idea how to make it work in a nice way.

Please note that this is code in progress, only very roughly tested, hence not yet committed to main dev branch. Would be cool though if someone played with it a bit too and shared the effects.

maciej.zgadzaj’s picture

FYI - branch 7.x-1.x-temporary-code has been deleted, all updates have been merged into 7.x-1.x branch, <media:category> element has been re-enabled, all fields should work fine now. Please read freshly added Setting up Media feed elements documentation for more info.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.