PHP general thought about database

994

Generally we use that database which is added without domain. For example you have domain calledexample.com then obtusely you will use that database or Myphpadmin. But is it possiblesuppose I haveexample.com domain and I want save any data which use fill from other website calledabcd.com show inexample.com How it would$conn structure?

422

Answer

Solution:

It's quite common that databases have another domain, i.e.mysql.example.com. This scenario can often be seen at hosting-companies.
Nevertheless it's a security-aspect to allow access only onlocalhost, then phpMyAdmin needs to be installed exactly on that server where the site is running, and when it's disabled or just not installed, then no access is possible.
So your scenario is nothing special.

Edit:
If your database is running without domain (not evenlocalhost) then the connection is by socket. This is common on servers when nothing else is configured. Technically it's still a bit different, if it's configuredlocalhost then a socket-connection is established, if you call the local IP-address 127.0.0.1 then a TCP-connection (like for a website). Nevertheless, both solutions can be seen as secure while the socket-connection requires another configuration for phpmyadmin.

People are also looking for solutions to the problem: java - Android app and Database Communication: JSON Parsing and List View

Source

Didn't find the answer?

Our community is visited by hundreds of web development professionals every day. Ask your question and get a quick answer for free.

Ask a Question

Write quick answer

Do you know the answer to this question? Write a quick response to it. With your help, we will make our community stronger.

Similar questions

Find the answer in similar questions on our website.