1 Reply Latest reply on Mar 17, 2017 10:44 AM by kerrishotts

    How to connect to localhost


      I have code a CRUD hybrid app but I've been having trouble connecting to the localhost(XAMPP).

      Currently my file is stored in XAMPP htdocs.


      How do i connect to the localhost on my mac(XAMPP) and where do i store the files?

        • 1. Re: How to connect to localhost
          kerrishotts Adobe Employee

          PhoneGap is not a server -- it does not parse PHP or do server-side stuff; therefore you will need your client code to make XHR requests to the backend. For devices on the same network (like your dev machine), you'll probably use an IP address in the 192.168.0.x range (your dev machine can tell you what its IP is). For production, you'll need a machine in the cloud somewhere with a domain name attached. (You don't /have/ to have the domain name, but having it allows you to change backends and IP addresses without updating the clients). Keep in mind that you need to be very concerned with security (use https://, review OWASP security guidelines https://www.owasp.org/index.php/Main_Page, etc.)