PHP: Parsing/Saving XML formatted Wordpress feed

Tibreinhene

New Member
I have a custom RSS feed formatted as XML.I have used rewrites to get the file to appear at these urls:http://www.mysite.com/feed/customfeed/&http://www.mysite.com/customfeed.xmlThe xml is being read by a flash Swf file.However flash is not recognising it at the above url (i'm guessing because it is a rewrite and not an actual file)I have tried using this code to save the feed as a physical file:\[code\]<?php$feedurl = "http://www.mysite.com/customfeed.xml";$feedme = file_get_contents($feedurl);if($feedme): $fh = fopen('/customfeed.xml', 'w+'); //create new file if not exists fwrite($fh, $feedme) or die("Failed to write contents to new file"); //write contents to new XML file fclose($fh) or die("failed to close stream resource"); //close resource streamelse: die("Failed to read contents of feed at $feedurl");endif;?>\[/code\]However i get this error:[function.file-get-contents]: failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in...I'm a bit out of my depth so any help would be very much appreciated.thanks in advance
 
Back
Top