Solved

How does a Website connect to the database.

Posted on 2012-04-11
4
352 Views
Last Modified: 2012-04-11
Hello:
My company has a website hosted in iPage.com, built with WordPress implementation.
That site connects to the company's SQL server in Chicago.

I would like to know HOW DO THE TWO COMMUINCATE?

Thanks you.
0
Comment
Question by:noamco36
  • 2
4 Comments
 
LVL 70

Assisted Solution

by:Jason C. Levine
Jason C. Levine earned 250 total points
ID: 37834575
Wordpress is written in PHP. PHP has function calls that allow you to connect to any database server that accepts remote connections and you have the ability to login to.
0
 

Author Comment

by:noamco36
ID: 37834626
can you give an example of PHP connection code to SQL server?

I dont know PHP language, but I want to be able to identify the connection code if I will take a look at the WordPress site code.
0
 

Author Comment

by:noamco36
ID: 37834647
Please see attached and explain.
connection.docx
0
 
LVL 1

Accepted Solution

by:
chrisroch earned 250 total points
ID: 37836169
PHP has many database related functions that are used for:
Managing Database connections
Manipulating database structure
Manipulating the data
among others...

The number of functions increase as there are different functions for different database implementations, however the simplest means of initiating a connection to a mysql database server is displayed in the code below:

$connection = mysql_connect("server_in_chicago","user","password");

Open in new window


If the above call is successful, there are other function calls that will have be used to extract data from the database.
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Let’s list some of the technologies that enable smooth teleworking. 
Data center, now-a-days, is referred as the home of all the advanced technologies. In-fact, most of the businesses are now establishing their entire organizational structure around the IT capabilities.
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now