Building A Website With Drupal 6
Building A Website With Drupal 6
In the first part of this tutorial we introduced Drupal 6. As part of your homework I asked that you
install a webserver and get an FTP program so that you can install and run Drupal. In this tutorial
we’re going to go ahead and start the process of installing and configuring our Drupal install.
The website that I am building and showing you screenshots of is Learn Drupal, the Drupal resource
site that I mentioned in the last post. I am building it online so that you can follow along or visit later
and see how different things that we mention here were implemented.
1. Create your settings.php file.
You can do this step before or after you upload the Drupal install files onto your server. Go into the
sites/default folder. Here you will find the filedefault.settings.php. Copy and paste this file and
rename the copy tosettings.php. So you should now have two files in the sites/default
folder - settings.php and default.settings.php. Drupal needs both of these files to exist for the
install to be successful.
2. Create Database
If you haven’t done so yet, upload the contents of your Drupal folder to where you’re going to have
your website. Also, you should already have created a database for your Drupal install and added a
user with all privileges to your database. Note this information somewhere.
3. Change Permissions: To be able to create your website, you will need to change permissions on
the settings.php file that we created in step 1 to make it accessible to Drupal during the install. You
can change permissions using your FTP program in most cases, or in cPanel if you’re developing
live. You can also use the CHMOD command if working from the command line. Change the
permissions on the settings.php file to 666. Once the installation is done, Drupal should change the
permissions to 555, and if it doesn’t, you should.
4. Run the Install: Assuming that all is set to go, open your browser and type the url of the site
where you’re creating your install. In my case it’s http://learndrupal.maryspad.com. In your case, if
you’re developing locally, it may be http://localhost/learndrupal or something similar. You will be
presented with the install screen.
I am going to be installing and running my site in English so that’s the option I’ll select.
The next step is to enter the database name, user, and password information we saved in step 2.
We don’t need to worry about the Advanced options at this stage and for this simple install. You can
open it to look at it, but generally the database host will always be localhost. The other options do
not apply to our simple install.
If you have entered the information correctly, you will see a screen allowing you to do some intial site
configuration. Enter your site name and email address in the indicated boxes. You can always
change these later in the site configuration.
As you can see from the screenshot, the permissions for the settings.php file that we changed in step
3 have been changed back for site security. The next step is to enter administration information as
below. Make sure you use a nice strong password.
And finally, check your server configuration settings.
If you server is set to allow clean urls then you definitely want to enable clean urls, for search engine
optimization reasons, so that your urls are clean and don’t have ?q= in them. If you can’t enable
clean urls, it means that your server is not set to allow mod-rewrite. Searching Google will dig up
lots of information on how to change your server settings to allow this. We won’t go into detail on
this at this point since our aim is to learn how to build a drupal site, but I’ll be happy to answer any
specific questions in the comments section.
You want to enable automatic update searching and notification so that you can always know when
you need to update your install for security and functionality reasons. The Drupal team is constantly
improving on Drupal and making sure all holes are patched and you want to stay updated to take full
advantage of this.
Once you’re happy with all your settings on this page, click Save and Continue and you will now see a
screen declaring that your site is installed and ready to go.
You’ll also notice that instead of saying “Drupal” at the top, our website now says “Learn Drupal” or
whatever site name you entered in the Site Configuration. If we click on the link that says “your new
site” or even just click on your site name at the top, it will take you to your brand spankin’ new
Drupal site.
If you’ve made it to this point, CONGRATULATIONS! You have a basic functional Drupal website!
We will pick up from this point on and continue to configure our website in Part 2 of this tutorial.