Hi,
I have an iBook with Mac OS X Panther (v 10.3.6) with AMP (Apache 2, MySQL 4, PHP 4) setup and working. I have installed Panther recently, and since that I have a problem which I don't know if it is related with Panther or not.
Before I installed Panther, when I had Jaguar, I developed Flash Applications that connected to MySQL through PHP with LoadVars, where PHP would make the bridge giving back XML to Flash.
It worked very well and I could test the swf's from Flash by apple+enter the fla's, the result would come, meaning that Apache would make PHP communicate with MySQL and back through PHP to Flash. I used something like this:
PHP Code:
(ActionScript)
// The path to the PHP file
php_responder = "http://localhost/clients/videodb/site/lib/responder.php";
// Function to send a MySQL query to that PHP file
function mysql2xml (query_str){
navXML = new XML ();
navXML.ignoreWhite = true;
nav_sender = new LoadVars ();
nav_sender.query_string = query_str;
nav_sender.sendAndLoad (php_responder, navXML, post);
navXML.onLoad = function (success) {
if (success) {
output = navXML.firstChild.toString();
} else {
trace ("No MetaXml!");
}
}
}
// Call the function
mysql2xml ("SELECT * FROM my_table");
The problem now is that with this fla when I apple+enter I get an error:
Error opening URL "http://localhost/clients/videodb/site/lib/responder.php"
And this is not because the PHP file is not there, I've tested with other scripts that attempt the same thing and it simply does not work. It works though if I publish the project and view it in a browser or even if I drop the swf in the browser (even if the swf resides out of my htdocs, like on my Desktop).
Also in my Network I have another computer with Mac OS X Jaguar (10.2.6) and it works fine with apple+enter in it.
So my question is: can this have something to do with the new Panther System? Does anyone have a simillar problem?
Already tried:
- "localhost", the network IP of the iBook and "127.0.0.1"
- permissions on all files within this project including the directories they are in
Thanks for reading!
Sckz