icor1031 Posted September 18, 2014 Share Posted September 18, 2014 (edited) I posted this on stackoverflow, but no one wanted to touch it. http://stackoverflow.com/questions/25903927/mysql-reverse-new-entries I've tried array_push, but the results remain as SimpleXML, and not a plain array, which I wasn't able to use. I tried some other things that I can't remember. $feed_url = 'http://feeds.feedburner.com/SlickdealsnetFP?format=xml'; $contents = file_get_contents($feed_url); $x = new SimpleXMLElement($contents); $arrayFPTitle=array(); foreach($x->channel->item as $temp){ array_push($arrayFPTitle, $temp->title); } Have any suggestions?... I've been on this problem for a few hours, now. I even tried regex, but you can imagine I quickly realized I wasn't going to figure that out. Edited September 18, 2014 by icor1031 Quote Link to comment Share on other sites More sharing options...
Solution mac_gyver Posted September 18, 2014 Solution Share Posted September 18, 2014 i didn't look at the specific data, but the following should work - array_push($arrayFPTitle, (string)$temp->title); // cast the element as a string Quote Link to comment Share on other sites More sharing options...
icor1031 Posted September 18, 2014 Author Share Posted September 18, 2014 Beautiful, thank you! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.