vimal Posted March 20, 2009 Share Posted March 20, 2009 Is there any way so that i can parse a a link http://feeds.currencysource.com/MUR.xml to my xml file on a server and it gets automatically updated !! and stored in database using php and do calcaulation currency converstion Sorry for my bad english Quote Link to comment https://forums.phpfreaks.com/topic/150285-helpparsing-xml-link-to-database-through-php/ Share on other sites More sharing options...
redarrow Posted March 20, 2009 Share Posted March 20, 2009 file_get_contents(); preg_match_all(); look them up. Quote Link to comment https://forums.phpfreaks.com/topic/150285-helpparsing-xml-link-to-database-through-php/#findComment-789234 Share on other sites More sharing options...
vimal Posted March 20, 2009 Author Share Posted March 20, 2009 Thanks for reply can u give me some sample code so that i can understand the logic please Quote Link to comment https://forums.phpfreaks.com/topic/150285-helpparsing-xml-link-to-database-through-php/#findComment-789240 Share on other sites More sharing options...
redarrow Posted March 20, 2009 Share Posted March 20, 2009 what you wanted i guess <?php $url=file_get_contents("http://feeds.currencysource.com/MUR.xml"); preg_match_all("/\<title\>(.*)<\/title\>/",$url,$matched); foreach($matched as $go){ foreach($go as $gon){ echo "$gon<br>"; } } ?> Quote Link to comment https://forums.phpfreaks.com/topic/150285-helpparsing-xml-link-to-database-through-php/#findComment-789275 Share on other sites More sharing options...
vimal Posted March 20, 2009 Author Share Posted March 20, 2009 Thanks again for explaining but i want from that link its automatically creates and update in file for eg called something.xml and then that code automatically sent to database just filling the currency value! in database .. its a like cron job Quote Link to comment https://forums.phpfreaks.com/topic/150285-helpparsing-xml-link-to-database-through-php/#findComment-789311 Share on other sites More sharing options...
redarrow Posted March 20, 2009 Share Posted March 20, 2009 goto the link you provided, and show on here pasted, what info you exactly want. we start from there ok. Quote Link to comment https://forums.phpfreaks.com/topic/150285-helpparsing-xml-link-to-database-through-php/#findComment-789318 Share on other sites More sharing options...
vimal Posted March 20, 2009 Author Share Posted March 20, 2009 thanks again for replying i want from above link http://feeds.currencysource.com/MUR.xml things like 1 Mauritian Rupee (MUR) = 0.107489 U.A.E. Dirham (AED) 1 Mauritian Rupee (MUR) = 0.092722 Argentine Peso (ARS) 1 Mauritian Rupee (MUR) = 0.042517 Australian Dollar (AUD) etc etc converted into xml and then updated in database by filling all the currency value according to MUR in relation to other country Like AUd shoud be 0.042517 just like that and script shoould automatically gets updated to database from this rss feed Quote Link to comment https://forums.phpfreaks.com/topic/150285-helpparsing-xml-link-to-database-through-php/#findComment-789623 Share on other sites More sharing options...
vimal Posted March 23, 2009 Author Share Posted March 23, 2009 help!!!! Quote Link to comment https://forums.phpfreaks.com/topic/150285-helpparsing-xml-link-to-database-through-php/#findComment-791601 Share on other sites More sharing options...
vimal Posted March 23, 2009 Author Share Posted March 23, 2009 where are everyone?? Quote Link to comment https://forums.phpfreaks.com/topic/150285-helpparsing-xml-link-to-database-through-php/#findComment-791731 Share on other sites More sharing options...
vimal Posted March 24, 2009 Author Share Posted March 24, 2009 PHP freaks get addicted Quote Link to comment https://forums.phpfreaks.com/topic/150285-helpparsing-xml-link-to-database-through-php/#findComment-792843 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.