HOW TO CONNECT FROM A PHP FILE TO A MYSQL DATABASE

One of the best
features of PHP is
how easily it interacts
with MySQL. This
allows you to store
information in a
database for your
website to access and
then create dynamic
content. In order to
do this you need to
be able to read and
write to the MySQL
database from your
PHP based website.
You can connect to
your database from a
PHP file with the
following code:

Obviously you need to
change the
highlighted items to
represent the actual
values for your
database.
Once you are
connected to your
database you can
read data or write to
your database.
http://www.facebook.com/BTtutorial

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s