Jump to content

clearmedia

New Members
  • Posts

    7
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

clearmedia's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Thanks for the quick response. The .xml file is on another server, it is a publically accessible file and gets updated twice a day so its not possible to have a local file.
  2. when using the mail() function it must be in the form of mail($to, $subject, $message, $headers) where $headers are optional. Your $to and $subject are fine, but you can't include Age, FirstName, LastName as you have them. Instead, put them into your $message variable. <?php $to = "****EMAIL*******"; $subject = "Contest Entry"; $Age = $_REQUEST['age'] ; $FirstName = $_REQUEST['first_name'] ; $LastName = $_REQUEST['last_name'] ; $message=$age." ".$FirstName." ".$LastName; $sent = mail($to, $subject, $message); if($sent) {print "Your mail was sent successfully"; } else {print "We encountered an error sending your mail"; } ?> This will send an email to $email with a subject $subject and the email itself will be Age FirstName LastName
  3. Hi folks, I am getting this error when running a script to parse an xml file: Warning: DOMDocument::load() [domdocument.load]: URL file-access is disabled in the server configuration Plus futher errors that result after this first one. The script that is producing these errors begins with: $xml=new DOMDocument(); $xml->load("ftp://ftp2.bom.gov.au/anon/gen/fwo/IDV10717.xml"); Can someone give my some advice on how to remedy this. The script was working until yesterday and now is throwing errors. Much appreciated, as usual my client is going off their head and the hosting provider seems to have no idea! Cheers Clearmedia
  4. All good! I realised I just needed to store the files outside of the _root directory and then access them with readfile($_SERVER['DOCUMENT_ROOT']."../textFiles/sometextfile.txt", 4096); hope this may help someone else though! thanks anyway
  5. Thanks for the replies folks. I actually need to set the permissions dynamically using a php script as the text files are created dyamically themsleves. I need to know how to chmod them at runtime.. Here's hoping!
  6. Hi happy freakers! I am need of a method to change permissions of text files on my server, so that my php scripts can still access (read/write) but so they cant be accessed by direct url... Thanks for any suggestions!
  7. i have an HTML form that has many txt fields, a few select fields and three file upload fields. The user entries in these fields are to be emailed on via a php page. I have worked out how to email all the results from the txt and select fields, but need to know how to attach the uploads to the email i am sending. Could someone advise please Thankyou
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.