Hi, I hope you can help me out. I would like to be able to pull an XML file from another site and then store it in a local folder on my site. That way, I would only need to pull the xml file once in a while instead of every time someone opens that page.
here is a snippet of code I found, but the size of the saved XML file is smaller and is not consistently the same size of file. Some of the information gets lost.
$fp = fopen( 'http://forecast.weather.gov/MapClick.php?lat=45.21640&lon=-112.63700&FcstType=dwml', 'r' );
$string = fread( $fp, 1024*9 );
fclose( $fp );
$fp = fopen( 'weather.xml', 'w' );
fwrite( $fp, $string );
fclose( $fp );
I hope I explained that
gmmktime or mktime
I live in the UK, i am within the GMT (with daylight saving time ie 1 hour difrence between summer and winter) Should i be using GMDATE and GMMKTIME or DATE and MKTIME... for all my date and time
ALV List display - header width adjust
Hi,
array_map() probably obvious mistake
The code below is part of a class to escape strings, but should also accept an array, using array_map() to do the job. Unfortunately, passing an array results in the original, unescaped array being
Applet JTextField Size Problem
Hello,I recently started making an applet to calculate certain values for airplanes. However, Gui has proved to be a problem. The JFormattedTextFields I am using have worked perfectly fine until I
Issues: PHP Forms -Clearing
I've tried looking online before actually asking for help, but I've been looking for about the past 3-5 hours and have found nothing that'll help me.This is a project for school, and well I have to
How to update this array?
I am saving a string that looks this: username1, username2, username3...into a single cell in a database table. I am doing this so that when I retrieve that string using normal methods, I can turn it
How to secure my login data to my database?
Hi there,It may be a stupid question but I don't know how to secure my login data to my database. I have created an include file in order not to have these data in the code of my pages, but I don't
Dynamic Array using glob?
Is there an easier way to do this?I am trying to get create a dyamic array based on files within the folder.Code: foreach (glob("*.jpg") as $filename) { $items = array("title"
Save file by click
Hello. I'm not understand how to save file from page. I'd like make link to file with save ability.<?phpchdir('upload/');foreach (glob("*.*") as $filename) { $uploadfile =
Passing PHP variables from one page to another
Hello-I'm having trouble figuring out how to transport a variable from one php file to another. Specifically, the name of an image, to be used as a subject in a form mail. I don't even really have the