简体   繁体   中英

I can't get Android app to connect to XAMPP Localhost

I've tried and searched the internet.I am very new to this so.... Does anyone know how to connect an Android app to a MySQL Database WITHOUT PHP?

I am using a PrintWriter and flushing two strings to a XAMPP Server Database,

I personally don't like using PHP err (referenced variables that don't even exist)

Basically I just have an app that sends login data to Server Database but I want to test it

any help appreciated!

QuestionOverflow I see here misconception Of what the PHP is and what MySQL Database for and the real question is "Is it possible to connect to MySQL database from android app?"

And the answer is NO. but why ...

We have android app which run on Mobile Device --> (client)

And server which runs MySQL Database Server --> (server)

The problem here is that the MySQL database server doesn't show it self to public to all clients.

Only programs that runs on the server can connect to the MySQL Database.

But how to save and get the data from my database ??!!

You should need a http end point like PHP that will be available to the clients and will connect to the MySQL Database and get the data and return them to the client (mobile app).

And if don't like PHP if you master it you will like it check this tutorial

enter link description here

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM