# Send out an xml object and save using php, HELP

**URL:** <https://forum.kirupa.com/t/send-out-an-xml-object-and-save-using-php-help/65863>\
**Category:** Uncategorized\
**Created:** [September 30, 2004, 4:43am UTC](https://forum.kirupa.com/t/send-out-an-xml-object-and-save-using-php-help/65863 "2004-09-30T04:43:34Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![fishbellyrust](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/fishbellyrust/32/784_2.png) [@fishbellyrust](https://forum.kirupa.com/u/fishbellyrust)\
**Post date:** [September 30, 2004, 4:43am UTC](https://forum.kirupa.com/t/send-out-an-xml-object-and-save-using-php-help/65863/1 "2004-09-30T04:43:34Z")

</div>

I’m trying to create a forum using Actionscript, XML, and PHP. I’ve read senocular’s XML tutorial, and am actually using bits of his code. I understand the concepts and the syntax. However, when I send out the XML object from flash, my PHP script will not save the raw GET data in my XML file. Yes, the PHP script is on the server where it should be. And other PHP scripts work. All the necessary files were uploaded. I’m 99.9% is simply a question of syntax or omission. My Actionscript is written as follows:

```
var my_xml = new XML();
my_xml.ignoreWhite = true;
my_xml.contentType = "text/xml";
my_xml.onLoad = function(success) {
    if (success) {
        var my_element = my_xml.createElement("bob");
        my_element.send(forum_save.php);
        _root.gotoAndStop(2);
    }
};
my_xml.load("my_document.xml");

My PHP script is written as follows:

&lt;?php
$filename = "my_document.xml";
$raw_xml = file_get_contents("php://input");

print $raw_xml;

$fp = fopen($filename, "w");
fwrite($fp, $raw_xml);
fclose($fp);
?&gt;

Your thoughts are much appreciated!
```

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [September 30, 2004, 10:01pm UTC](https://forum.kirupa.com/t/send-out-an-xml-object-and-save-using-php-help/65863/2 "2004-09-30T22:01:21Z")

</div>

Anything? Anybody? I’m pulling my hair out.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [October 1, 2004, 9:44pm UTC](https://forum.kirupa.com/t/send-out-an-xml-object-and-save-using-php-help/65863/3 "2004-10-01T21:44:30Z")

</div>

You guys suck.
