zerog
asked on
Display PHP content using Adobe AIR
I used the following snippet to create a wrapper in FlashBuilder for an html/php application.
I have a local server running to serve the PHP pages. The problem I have is that the html pages display perfectly except the ones that have PHP code in them. Is there something I'm doing wrong? I'm using FlashBuilder 4.6
<mx:HTML id="myBrowser" location="http://127.0.0.1/index.html"
width="100%" height="100%" />
I have a local server running to serve the PHP pages. The problem I have is that the html pages display perfectly except the ones that have PHP code in them. Is there something I'm doing wrong? I'm using FlashBuilder 4.6
ASKER
In the PHP example I was linking to
But I just get a blank.
<mx:HTML id="myBrowser" location="http://127.0.0.1/index.php"
width="100%" height="100%" />
But I just get a blank.
What do you get when you point your browser to http://127.0.0.1/index.php ?
ASKER
Thank you for your prompt response. When I point my browser to the php page on local server it fine as it suppose to be.
Some background:
I'm using Server2Go as a local WAMP server. The settings in Server2Go allow you to execute an EXE when the server is started. I've set it to execute the testAIR.exe that I created in FlashBuilder. The code that makes up testAIR.exe is
Maybe I should upload a sample ZIP of everything.
Some background:
I'm using Server2Go as a local WAMP server. The settings in Server2Go allow you to execute an EXE when the server is started. I've set it to execute the testAIR.exe that I created in FlashBuilder. The code that makes up testAIR.exe is
<mx:HTML id="myBrowser" location="http://127.0.0.1/index.php"
width="100%" height="100%" />
With all the stuff in the same folder I tried changing the location to index.php, but it still didn't work. Maybe I should upload a sample ZIP of everything.
OK, so we know that the PHP script is not part of the problem. I think my next test would be to replace http://127.0.0.1/index.php with the URL of a known resource that contains a very simple HTML document. If that works in the context and the PHP script fails, it would indicate to me that the PHP parser is not getting called in the context.
ASKER
Will try that. If I change location to index.html, then testAIR.exe shows the html page. But maybe I should link to the html page using the local URL i.e. http://127.0.0.1/index.html
Will update you.
Will update you.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you for the your detailed response in trying to help eliminate the problem I was experiencing. Using your code snippet, it seems that the testAIR.exe was calling the php file before the server2go WAMP stack was starting the server and php modules. Although the delay between the start up of the two was just a few seconds, it's what caused the problem.
Thanks for the points -- it's a great question! And thanks for using EE, ~Ray
Perhaps you can set up the SSCCE that demonstrates the issue? Then we can try to duplicate the problem on our servers, and maybe can get a little more insight.