Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 08-21-2006, 02:30 PM   #1
flashforarmy
Registered User
 
Join Date: Aug 2006
Location: Louisville, KY
Posts: 2
Question Write XML to local file PROBLEM!

I'm trying to write XML to a local file using PHP or ASP. It seems to work but the file never shows up. Am I missing something with the permsissions? Please help. Here's the details:

Flash 8

on (release) {
// A. Construct a XML document with a LOGIN element
loginXML = new XML();
loginElement = loginXML.createElement("LOGIN");
loginElement.attributes.username = "MyDog";
loginElement.attributes.password = "barkbark";
loginXML.appendChild(loginElement);
loginXML.contentType = "text/xml";

// B. Construct a XML object to hold the server's reply
loginReplyXML = new XML();
loginReplyXML.onLoad = onLoginReply;

// C. Send the LOGIN element to the server,
//place the reply in loginReplyXML
loginXML.sendAndLoad("save3.php", loginReplyXML);

PHP

<?
$filename = "xmloutput.txt";
$fp = fopen( $filename,"w+");
fwrite ( $fp, "$HTTP_RAW_POST_DATA" );
fclose( $fp );
print '<?xml version="1.0"?><result>LOGIN OK</RESULT>';
?>
flashforarmy is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Write text to file aniWiz JSFL - Extending Flash 3 06-08-2006 04:49 PM
Problem with calling external file theeggert ActionScript 2.0 3 03-18-2006 07:43 PM
problem w/ sound object file loading into a holder file echolizard ActionScript 2.0 0 03-14-2006 02:54 PM
Is it possible to write to an external text file? jaime ActionScript 2.0 6 08-31-2005 06:00 PM
problem with php writing to file nahdan Server-Side Scripting 3 03-14-2005 09:15 PM


All times are GMT. The time now is 05:12 PM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.