Jump to content

How to host my blog?


Lykos22

Recommended Posts

Hi, i' going to create a simple blog with php and mysql as an exercise for my college and i thought it would be a great idea to host it online for the day of presentation. I don't know much about web hosting, so i thought this would be a great chance to learn also how to host a website.I would like to know if or whether i have to make any changes in my html or php when i have to move my blog from localhost (using xampp) to the server, so in which points should i pay attention. For example my connection file (localy in xampp) i have set it up like this:

$host = "localhost";$username = "root";$password = "";$database = "my_blog";$connection = mysql_connect($host, $username, $password);$select_db = mysql_select_db($database, $connection);

What exactly changes do i have to make in here? Does this also has to do anything with this http://w3schools.invisionzone.com/index.php?showtopic=45537 ?

Link to comment
Share on other sites

The easy answer is that you have to change anything that changes. The host name may be the same, or the live server may use a socket format for that. Your host should be able to tell you what host name to use. If your username changes, then change that. If your password changes, then change that. etc..

Link to comment
Share on other sites

Thanks for the reply! Ehh .. just one more question please, more general. I was watching some videos on youtube about hosting, watching pretty much the progress with filezilla etc, but i was just wondering, for example a web development company hosts all the sites with the same way (getting domain, setting up a database etc etc), or they have their own database and they upload the sites they create in a subfolder in their site? Does the sub-domains that most hosting-companies offer has anything to do with this?

Edited by Lykos22
Link to comment
Share on other sites

They can set that stuff up however they want to. When we get a new client and set up a new installation of our application we have an automated script that uses the cPanel API to create a new hosting account, set it up with a username and password, apply permissions, create the default database, install all of the files, etc. I just tell it what I want the domain name to be and which version of the application to install and it does everything else.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...