+ 10

How to parse xmls feeds from providers to show nicely in php run website.

Example of xmls data feeds are sport content in forms of xmls that you need to show up dynamically in wordpress/php site. The feeds show teams, players, scorers, soccer tables, results and match schedules all in xml feeds form. These are stored on xml feeds provider's ftp so you pull them and parse them from the php site. That's how best I could explain myself. Hope you understand my question.

26th Jan 2017, 3:09 PM
Danstan Ongubo
Danstan Ongubo - avatar
2 Réponses
+ 7
Thanks a lot.
27th Feb 2018, 6:57 PM
Danstan Ongubo
Danstan Ongubo - avatar
+ 1
There is a function built in to php called get_file_contents(). Provide the url of the xml feed and php will load the xml into a variable. Then use an xml library to parse through the tree to extract the values you are interested in.
28th Jan 2017, 6:19 PM
Kevin Gilkey-Graham
Kevin Gilkey-Graham - avatar