4 Replies Latest reply on Aug 5, 2011 1:20 AM by isabelle loyer

    Connecting Air Application to a Remote MySQL database

    William Spence Level 1

      I am going to go the very long road to asking a pretty simple question:  What is my Web root and Root URL for configuring a remote server where my database is sitting.


      I am writing an Air application that will be deployed to many users desktops.  It will need to access a database on the web to obtain data.  I understand that to access the database remotely, Air needs to use PHP or BlazeDS.  I have a web server with InMotionHosting that has Apache, PHP, and MySQL installed and I already have a database sitting out there waiting to be tested.  The problem is that I cannot get connected in Flash Builder.  After reading a lot of tutorials, I was going to use the Zend Framework to assist in connecting to my database, but first you have to configure a server connection and I have not been able to do it.


      A lot of the tutorials and available documentation all suggest installing WAMP and having Apache, MySQL, and PHP all on your local machine.  You would then set up your connection using "localhost" but this assumes that your database and application are going to be on the same server such as a browser-based Flex application.  But since I want my Air application to be on a client, and the database to be on a server, "localhost" simply will not work.


      I set up the database on a remote webserver and I want to start all of my coding with this in mind and to stay away from using WAMP.  In that case, how do I set up my Web root and Root URL when I set up a new Flex project so that I can use Zend?


      Maybe I am lost, maybe you still need to have PHP server on your local machine???


      Either way, any help getting the server technology set up so that I can get connected to my remote database using Air would be greatly appreciated.


      (I thought that if my website was http://www.mydomain.com, that this would be my root URL, and that /public_html would be my Web root, but it has failed miserably)