Jump to content

Read Rss Feed And Put Into Array


Pythondev

Recommended Posts

Ok,

I want to read a RSS feed and extract some of its contents and put them into arrays.

For example take a look at this snippet of an RSS feed from my site:


[code]<item>
<title>Glass Material</title>
<link>
http://www.tutorialdash.com/tutorial/3d-studio-max/textures/view/Glass-Material
</link>
<description>Glass Material - 3D Studio Max Tutorials</description>
</item>
<item>
<title>Cool Explosion</title>
<link>
http://www.tutorialdash.com/tutorial/3d-studio-max/special-effects/view/Cool-Explosion
</link>
<description>Cool Explosion - 3D Studio Max Tutorials</description>
</item>
<item>
<title>Cigarette Smoke</title>
<link>
http://www.tutorialdash.com/tutorial/3d-studio-max/special-effects/view/Cigarette-Smoke
</link>
<description>Cigarette Smoke - 3D Studio Max Tutorials</description>
</item>[/code]

There are three items here - after running it I want to have an array something like the following...

$item[0] = first item
$item[1] = second item
$item[2] = third item

$item[0][0] = first items title
$item[0][1] = first items link



etc..... How can this be done?


Remember this will in fact go through 25+ items each time not just 3...

Thanks
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.