may be i am going to ask some stupid question but i don’t have any idea about php
that’s why i want to know it i never worked in php and now i have to do it so please provide me some useful tips,
i have XML file that is coming from a different URL and i want to save it on the server then i have to read it and extract it to a page in proper format and some modification in data.
may be i am going to ask some stupid question but i don’t have
Share
You can use DOM
This would load the XML from the remote URL. You can then process it as needed. See my previous answers on various topics using DOM. To save the file to your server after your processed it, you use
Loading the file with
$dom->load()will only work if you haveallow_url_fopenenabled in your php.ini. If not, you have to use cURL to download the remote file first.