Re: [Magpierss-general] How to target multiple elements value?
Status: Beta
Brought to you by:
kellan
From: Doti, A. <Ada...@vi...> - 2006-07-01 17:07:18
|
Thanks! I did FINALLY end up finding some instructions to help me here: = http://laughingmeme.org/articles/2005/11/05/towards-magpierss-0-8-repeati= ng-elements-attributes-and-atom-1-0 = <http://laughingmeme.org/articles/2005/11/05/towards-magpierss-0-8-repeat= ing-elements-attributes-and-atom-1-0>=20 =20 Why they aren't on the main Magpie site is beyond me! =20 Also what was confusing was the author referred to the version number = that had his fix was the same that I had installed (the ZIP file was = same name), but upon closer inspection he contents were indeed = different. So I reinstalled and works now as long as I use his pseudo = code instructions above. =20 -A =20 ________________________________ From: Adam Scheinberg [mailto:asc...@gm...] Sent: Sat 7/1/2006 6:20 AM To: mag...@li...; Doti, Adam Subject: [Magpierss-general] How to target multiple elements value? I came up with a "semi-fix" for this. It won't separate them, it will just prevent the concatenation and give you one category. See the URL below. http://firsttube.com/read.php/1150315251/magpierss_bug_fixed.html -- Hello there. I am trying to find out a way to parse and display the below "category" elements in my PHP pages. I for the life of me can not figure out how top identify the category element and specifically which one to render the value of. Any help on how I write my code would be greatly appreciated. I've tried $activityType =3D $item['category']; But obviously that just renders "Mountain BikingadotiTrainingGeronimo, Marin, California, United States" - <item> <title>Woodside to Olema and the Cross Marin Trail.</title> = <link>http://trail.motionbased.com/trail/episode/view.mb?episodePk.pkValu= e=3D977239</link> <description><a href=3D'http://adoti.motionbased.com' title=3D'View public activities for adoti'>adoti</a> recorded a <a href=3D'http://trail.motionbased.com/trail/network/digest/view.mb?keyword= Search=3DMountain Biking' title=3D'View trailnetwork activities forMountain Biking'>Mountain Biking</a>activity starting at 6/28/06 6:51 PM near <a = href=3D'http://trail.motionbased.com/trail/network/digest/view.mb?keyword= Search=3DSan Geronimo, Marin, California, United States' title=3D'View TrailNetwork activities in San Geronimo, Marin, California, United States'>San Geronimo, Marin, California, United States</a>. The acitivity was a Training event which went a distance of 21.34 miles and took 4 hours 11 minutes 19 seconds. Ride out to Olema to visit Brian and Leigh at the Flying Cloud for dinner.</description> <pubDate>Wed, 28 Jun 2006 6:51:46 PST</pubDate> <category domain=3D"http://www.motionbased.net/activity/type">Mountain Biking</category> <category = domain=3D"http://www.motionbased.net/username">adoti</category> <category = domain=3D"http://www.motionbased.net/event/type">Training</category> <category domain=3D"http://www.motionbased.net/location/absolute">San Geronimo, Marin, California, United States</category> <georss:point relationshiptag=3D"start" featuretypetag=3D"track">38.00747 -122.66575</georss:point> <georss:box>38.00026 -122.7912 38.04993 -122.66253</georss:box> </item> -- Adam Scheinberg |