i was wondering how can i extract data from this xml feed http://www.myhoroscop.ro/feeds.xml change the link from <link></link> and save the text automaticaly
you need a xml parser, you have a variety of parsers, depending on which programming language you use
Please look at this link http://www.kirupa.com/web/xml_php_parse_beginner.htm HTML: you should open the xml file in browser and view the source code, or download it to your pc. The xml is simple. here is another link http://www.criticaldevelopment.net/xml/doc.php HTML:
Try this: $doc = new DOMDocument(); $doc->load("http://www.myhoroscop.ro/feeds.xml"); $linkArray = array(); foreach ($doc->getElementsByTagName('item') as $node) { $link = $node->getElementsByTagName('link')->item(0)->nodeValue; $linkArray[] = $link; }
Check these links about reading RSS/XML feeds How to Read RSS Feeds with PHP 5 How to read RSS feed XML Using PHP cURL