ldoozer Posted July 11, 2008 Share Posted July 11, 2008 Hi all, I have a XML file on an external url that I want to access daily and import all the XML nodes or fields in to my database so that they can be queried and used in a search function. I have crontab on my server and so i know that i can run a script on a daily basis, but I have no idea how to write the script. Any help or example scripts would be very much appreciated. Quote Link to comment https://forums.phpfreaks.com/topic/114271-xml-from-a-url-importing-in-to-a-mysql-database/ Share on other sites More sharing options...
ldoozer Posted July 11, 2008 Author Share Posted July 11, 2008 sorry for got to say, the server has PHP Version 4.3.10 installed. Quote Link to comment https://forums.phpfreaks.com/topic/114271-xml-from-a-url-importing-in-to-a-mysql-database/#findComment-587587 Share on other sites More sharing options...
ldoozer Posted July 11, 2008 Author Share Posted July 11, 2008 The person providing the URL to the XML says I can just use a simple soap request. don't know if that helps? Quote Link to comment https://forums.phpfreaks.com/topic/114271-xml-from-a-url-importing-in-to-a-mysql-database/#findComment-587596 Share on other sites More sharing options...
Danltn Posted July 11, 2008 Share Posted July 11, 2008 PHP only has the SOAP library installed in PHP 5+ (although there are workarounds.) Seriously though, upgrade that PHP. PHP 4 was released in 2000, PHP 5 was released in 2004. Dan Quote Link to comment https://forums.phpfreaks.com/topic/114271-xml-from-a-url-importing-in-to-a-mysql-database/#findComment-587645 Share on other sites More sharing options...
ldoozer Posted July 14, 2008 Author Share Posted July 14, 2008 i am hosted on a webfusion shared hosting platform and don't think i can upgrade it. There must be an easy way to read all the elements of an xml file and insert them into a database. any one? Quote Link to comment https://forums.phpfreaks.com/topic/114271-xml-from-a-url-importing-in-to-a-mysql-database/#findComment-589807 Share on other sites More sharing options...
ldoozer Posted July 29, 2008 Author Share Posted July 29, 2008 i have done lots of searching now and still haven't found a solution to my problem. Someone must have done this before - would really appreciate your help. Quote Link to comment https://forums.phpfreaks.com/topic/114271-xml-from-a-url-importing-in-to-a-mysql-database/#findComment-603106 Share on other sites More sharing options...
Barand Posted July 29, 2008 Share Posted July 29, 2008 This is available for v4 http://www.php.net/manual/en/book.xml.php Quote Link to comment https://forums.phpfreaks.com/topic/114271-xml-from-a-url-importing-in-to-a-mysql-database/#findComment-603149 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.