Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4123564
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T23:37:38+00:00 2026-05-20T23:37:38+00:00

I’m sure this is a simple problem, so my apologies in advance for even

  • 0

I’m sure this is a simple problem, so my apologies in advance for even asking it. In the code below, I’m converting an RSS feed to JSON using the jGFeed plugin. Within this JSON, I need to access a URL node that is nested several levels deep, inside a nested array. Right now, I’m able to use “console.log(“feeds.entries[i]”)” to get some attributes of each object at the parent level (i.e., “title”, “content”, etc.). I just can’t figure out how to drill down into the nested array.

This is my code:

$(document).ready(function() {

    $.jGFeed('http://feeds.feedburner.com/solidverbal/app', function(feeds){
        // Check for errors
        if(!feeds){
        // there was an error
        return false;
        }
        var sAnchors = "<ul>";
        //var wantedFeed = "";
        for(var i=0; i<feeds.entries.length; i++){
            console.log(feeds.entries[i]); 
            var sAnchors = sAnchors + "<li><a href=\"#link\" id=\"title_" + i + "\" class=\"giveFeeds\">" + feeds.entries[i].title + "</a></li>";
        }
        sAnchors = sAnchors + '</ul>';

        //Append the <a>.
        $('#titles').append(sAnchors);

        //When the user clicks on the giveFeeds link....
        $('.giveFeeds').live('click', function(e) {

            //Get the feed number
            var tmpId = $(e.target).attr("id");

            //Returns the value after the '_' char and make sure it returns de number.
            var id = parseInt(tmpId.split("_")[1]);

            //Use the id value to get the desired feed
            var wantedFeed = feeds.entries[id].content;

            //Then do whatever you want with that entry
            $("#content").html(wantedFeed);
        });


    }, 20);
});

Here is an example of the JSON structure as it appears within the Chrome console:

Object
     author: "Test"
     categories: Array[10]
     content: "<p></p><p>Test Content"
     contentSnippet: "Test Content Snippet"
     link: "http://www.solidverbal.com/2011/03/24/charles-robinson-324/"
     mediaGroups: Array[1]
          0: Object
               contents: Array[1]
                    0: Object
                         fileSize: "12796261"
                         type: "audio/mpeg"
                         url: "http://www.testurl/test.mp3"

Any help would be greatly appreciated. I’m thinking it’s a nested for-loop or something, but for whatever reason I just can’t get it.

Thanks in advance!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T23:37:39+00:00Added an answer on May 20, 2026 at 11:37 pm

    It is just like navigating the object graph in Java or C#, you can do feeds.entries[0].link to get the Url or feeds.entries[0].mediaGroups[0].contents[0].fileSize

    for (var i = 0; i < feeds.entries.length; i++) {
        var entry = feeds.entries[i];
        for (var j = 0; j < entry.mediaGroups.length; j++) {
            var mediaGroup = entry.mediaGroup[j];
            for (var k = 0; k < mediaGroup.contents.length; k++) {
                var content = mediaGroup.contents[k];
                // do something with content.url.
            }
        }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

No related questions found

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.