homepage Welcome to WebmasterWorld Guest from 54.226.235.222
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
Forum Library, Charter, Moderators: coopster & jatar k

PHP Server Side Scripting Forum

    
How do I access an xml string value with SimpleXML?
sysdomatic




msg:3903924
 10:15 am on Apr 30, 2009 (gmt 0)

Hello everyone

I'm a bit stumped with this problem. The solution is probably fairly simple, but I've spent hours trying to figure this out.

$tweeters = new SimpleXMLElement($twi);

I do a var_dump($tweeters) and I get this..

object(SimpleXMLElement)#1 (4) { ["reset-time-in-seconds"]=> string(10) "1241085902" ["remaining-hits"]=> string(2) "40" ["hourly-limit"]=> string(3) "100" ["reset-time"]=> string(25) "2009-04-30T10:05:02+00:00" }

Now how the heck do I access the "remaining-hits" string in this array?

Thanks very much,

Dave

 

sysdomatic




msg:3903937
 11:02 am on Apr 30, 2009 (gmt 0)

Thanks guys - figured it out.

Dave

coopster




msg:3903970
 12:13 pm on Apr 30, 2009 (gmt 0)

Glad you got it sorted. Care to share the expression that shows how to access that string? It may help a future reader ;)

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved