Need help pulling other fields from an RSS feed.

  • Sam Harney
  • Sam Harney's Avatar Topic Author
  • Offline
  • Junior Member
2 weeks 3 days ago - 2 weeks 3 days ago #176622 by Sam Harney
RSS Feed:
feed xmlns:yt="" xmlns:media="" xmlns="">
<link rel="self" href=""/>
<title>Greg Crawford</title>
<link rel="alternate" href=""/>
<name>Greg Crawford</name>

I'm trying to either create a custom template for Simple RSS Feed Reader, or even modify the core module file if needed, but I need to pull this field yt:videoId. The problem is that even though I have duplicated the PHP code that pulls other fields from the XML file if I use the field title for the video id yt:videoId then I get an error message about the ":" not being expected... I've tried a ton of different ways of formating the name of the field to see if SRFR was modifying the name in the variables as it pulls the feed; however, if SRFR is doing that I cannot figure out. I need this so that I can have SRFR auto-embed the videos in the site.

Here is the code I'm trying to add into my "YouTube" template which is just a modification of the default template for this module:
<iframe width="420" height="315" src="<?php echo $feed->yt:videoID; ?>" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
Last edit: 2 weeks 3 days ago by Sam Harney.

Please Log in or Create an account to join the conversation.

  • Fotis
  • Fotis's Avatar
  • Offline
  • Administrator
  • JoomlaWorks Support Team
2 weeks 1 day ago #176626 by Fotis

If you use & love K2, please take a moment to add your review and rate it
at the Joomla Extensions Directory:

IMPORTANT: Please search the forum before posting a question!

JoomlaWorks Support Team Member

Please Log in or Create an account to join the conversation.

Powered by Kunena Forum