Installing and Administering Drupal Site Building Extravaganza

twodotcuddlyInternet and Web Development

Dec 4, 2013 (4 years and 27 days ago)

109 views

Installing
and Administering
Drupal
Site Building Extravaganza
By Emma Jane Hogbin
Installing Drupal
© 201
1
by Emma Jane Hogbin
440-13
th
Street East
Owen Sound, Ontario
N4K 1W6
www.designtotheme.com
emma@designtotheme.com
License
Creative Commons: Attribution-Noncommercial-No Derivative Works 2.5 Canada
unless otherwise noted.
All photos © Emma Jane Hogbin and licensed as CC-BY unless otherwise noted.
Cover Photo Credit: Grégory Tonon. Available under CC-BY-SA license.
http://www.flickr.com/photos/eriatarka31/3392276341/
About this Workbook
This workbook was created by Drupal expert Emma Jane Hogbin (
www.designtotheme.com
). It is the result of

years of experience and many hours of work.
It is
dedicated to making this topic easier for you to quickly

master—so that you can
create
a more profitable experience with Drupal. That said, mistakes sometimes sneak

into workbooks. If you've found an error—please let me know by email.
Th
is
workbook
was
produced by Design to Theme
as part of a year-long training program in 2011. Content was

originally released to the participants of the program.
If you were lucky to get this copy for free, we encourage

you to consider how valuable it was to you and send that amount of money via PayPal to

emma@designtotheme.com
.
You are not allowed to sell
this
workbook
or
extract parts of it
to create “derivative” works
.
(I've already nailed

one
person
who tried selling my stuff on his site
without permission
. Don't be that guy. Ok?)

You are

encouraged to share the work digitally with others for free so long as the entire PDF (including all the pages)

are included. You are also welcome to share print copies of the document with others—again only the
entire

document may be shared
.
If you're a
Drupal trainer
and you're interested in using this workbook in your classes: get in touch to find out

more about
licensing this workbook
with your own logo
for your next workshop
.
We hope you enjoy this workbook. If you do, tell the world. If you don't, tell
Emma
!
About Design To Theme
Emma Jane Hogbin is the founder of a great little Drupal consulting and training agency.
She makes theming

Drupal easier, faster and more profitable.

Drupal
S
ite
B
uilding
C
onsulting
:
We're great at saving you money. There are thousands of Drupal

modules out there that will
get you from idea to finished Web site faster and with higher
profit
s
. With

a Site Building Consultation we can help you choose (install and configure) the
best
modules for your

next project.
If you're tired of handing over all your profits to your programmer we need to talk.

Support
for Small Businesses and Designers
:
Did you get in over your head a little bit with a project?

We can help you get unstuck with gentle technical support that will make you feel smart and

wonderful and capable of taking back control of your Drupal project.

Drupal
T
raining
:
Drupal site building and theming t
raining sessions are available
on-line. Check the

web for a list of upcoming workshops. Custom training is also available
.
Accolades
“Emma is an amazing teacher.” — Betty
“Thank you for sharing your experience through e-books in addition to seminars and presentations. It's really

helpful to have short,
easy-to-use examples to learn from as well as refer back to
while trying to develop

good Drupal theming skills.” — Spence
“Emma Jane worked with me on a dramatically ambitious Drupal project a couple of years ago. She managed

to keep my overactive imagination in check so we focused on realistic goals and milestones, all the while

making me feel like I could get my hands dirty
in the project. She was timely, proficient, and a joy to work

with.”
— Kim
Werker, founder of CrochetMe.com
“Emma Jane combines the perfect amount of predictability and spontaneity...her technique has
sparked my

excitement
about developments in technology and has inspired me to engage in new projects. She presents

herself as very approachable and always answers questions thoroughly, making sure that the user feels

comfortable and at ease.” — Jorge Castro, External Developer Relations, Canonical Ltd.
“Taking your course is one of the
best investments I have made
.” —
Louise
Table of Contents
About Design To Theme
.............................................................................................................
3
Accolades
................................................................................................................................
3
Hosting Your Web Site on the Internet
..........................................................................................
5
Internet Service Providers (ISP)
................................................................................................
5
Domain Name Registration
.......................................................................................................
5
Web Site Hosting
........................................................................................................................
5
Web Site Maintenance
...............................................................................................................
6
Installing Drupal
.............................................................................................................................
6
One-click Installation on WebEnabled
......................................................................................
7
One-Click Install via the WebEnabled Marketplace
.............................................................
7
Site Clones
..............................................................................................................................
9
Working with Sites on WebEnabled
......................................................................................
9
DIY Installation
..........................................................................................................................
9
Minimum Requirements
.......................................................................................................
9
Creating a Database for Drupal
...........................................................................................
10
Preparing the Drupal Files for Installation
.........................................................................
10
Multisite
................................................................................................................................
13
Sandboxes for Testing and Demonstrations
.......................................................................
13
Drupal’s Install Wizard
.............................................................................................................
14
Administering Drupal
...................................................................................................................
17
Administrative Overlay
.............................................................................................................
18
Administrative Toolbar
.............................................................................................................
19
Administrative Shortcuts
..........................................................................................................
19
Hiding the Shortcuts
............................................................................................................
20
Administrative Dashboard
.......................................................................................................
20
Configuration
.................................................................................................................................
21
Site Information
.......................................................................................................................
22
Theme Configuration
...............................................................................................................
24
Adding a Site Logo
...............................................................................................................
24
Adjusting the Colors
.............................................................................................................
25
Date, Time and Regional Settings
............................................................................................
25
Administrative Reports
.................................................................................................................
27
Help
...............................................................................................................................................
29
About The Author
..........................................................................................................................
31
Hosting Your Web Site on the Internet
Although Drupal itself is free having a Web site is not. There are at least five parts to being
on-
line
and having a web site:

your personal or business Internet connection

annual domain name registration fee

Web site hosting

web site development

web site maintenance
If you expect a large proportion of your marketing to happen via email you will also want to

hire an Email Service Provider that specializes in newsletter delivery.
Internet Service Providers (ISP)
An Internet Service Provider (ISP) will connect your computer to the Internet. This is the

service you will use to check your email, and surf the web. Your ISP may offer you a small

amount of Web space with your Internet connection for free, and/or they may have a discount

on web hosting for customers who already use one of their services. “Free” hosting packages

typically come with an address like this: www.bmts.com/~gingerpress and are not suitable for

Drupal.
Domain Name Registration
If you want to have your own “dot com” you will need to register a domain name. This name is

the address that people will use when they visit your web site. This may be your business

name (for example www.gingerpress.com for The Ginger Press) or a variation of your business

name (for example www.artsonline.ca for Community Arts Ontario). You should expect to pay

no more than $25USD per year for a domain name—
it should be closer to $10/year
. This fee

grants you the right to use the domain name for your Web site in the same way as a business

license gives you permission to operate a business with a specific name. This fee does not

cover the “hosting” of your web
site
.
Domain name registration can often be performed by the web hosting company. If you know

who you will be using to host your web site, ask them if they will also register your domain

name for you. For someone who is comfortable with domain name registration this is typically

a quick procedure; however, some hosting companies will charge a small setup fee to register

a name for you. Be sure to ask ahead of time if there is a setup fee. Ask that your name and

contact information be included on the registration to secure your ownership over the domain

name.
Web Site Hosting
You will need somewhere to install Drupal so that others on the Internet can view your Web

site. Expect to pay $10-$50/month for web site hosting and a mailing list. Most companies

that offer Web site hosting will have a range of packages with different options.
Features included in hosting packages can vary. Specific requirements for installing Drupal

are listed later in this chapter. When comparing hosting companies look for the following

options:

unlimited databases

PHP scripting language

unlimited data storage

unlimited data transfer (or reasonable rates if your suddenly suddenly becomes very

popular)

one-click install of Drupal (optional)

file and database backups

technical support
Additional nice-to-haves include:

web site statistics

mailing list
It is very unlikely you will find a hosting company with unlimited
anything
. That’s ok. There

are all kinds of horror stories about people who were suddenly faced with very large hosting

bills when their Web site got wildly popular. You don’t really need unlimited capacity, but you

do need to be with a company that will treat you reasonably when your zombie brain cookies

are featured on Martha Stewart Living.
If you are not very technical, and you are hoping to build your own Web site, be sure to look

carefully at the support your hosting company provides. Find answers to the following

questions:

When is technical support available (24x7 or 8x5)?

How do you get in touch with technical support? Do you phone them, or do you fill out

an online form to start a support ticket?

Is there a limit on the number of support questions you can ask per month?
Read your contract carefully before signing up.
Note: there is a list of Web hosts listed in the

SBE Web site. This is a community-maintained document. Use at your own “risk”.
Web Site Maintenance
In most cases this is as simple as point, click, type, point, click! If you currently pay someone

to update your Web site you may end up being able to save on those costs as you learn how to

update your own site with Drupal.
Installing Drupal
Ultimately your Drupal site needs to end up somewhere that others can see it; however, when

you're first learning you should create a private (or semi-private) space where you can make

mistakes. If you are new to Web site development, proceed with the instructions for

WebEnabled; if you have a lot of system administration experience, or you're on a dial-up

Internet connection, you'll probably want to proceed with the DIY Installation. Technical

support for WebEnabled is provided by WebEnabled. You're on your own if you choose the

Do-It-Yourself Installation
route
.
One-click Installation
on WebEnabled
One-click installs are not available from every hosting provider. They do have some

disadvantages: they might be modified slightly to work efficiently on your hosting provider’s

system. For the most part you shouldn’t notice the differences; however, there may be

additional modules installed which are not described as part of the base install in this book.

The biggest advantage of a one-click install is that it’s easy! You won’t need to worry about the

minimum system requirements or making a database or any of that froo-f’rah technojumble.
Each one-click install process is a little bit different. Your hosting company will be able to help

you through the installation process if you have questions.
In this workbook we cover

installing Drupal on WebEnabled using both their one-click install and cloned sites.
One-Click Install
via the WebEnabled Marketplace
In this section you will learn about setting up a test Web site on WebEnabled

(
www.webenabled.com
)
.
If you don't already have an account, you will need to create one

now. The free account is fine (it's listed in fine print below the paid accounts on

http://www.webenabled.com/plans-and-pricing
).
Yes, the
free
accounts expire after 30 days,

but this is long enough to install your site, poke at it and then migrate it onto your Web server.
Once you've created your account, log into your account. The URL will be something like,

http://mynickname.webenabled.com
.
Now you need to select an install profile from the Marketplace:
1.
Navigate to the “overview” tab for your account.
2.
On the right hand side is a button labeled, “Start new site.” Click that button.
3.
Find the Drupal 7 install profile and c
lick the link “Select this app to install” to proceed.
4.
On the following screen, you can fill out the “Site Name” field in order to give your site

a more meaningful name.
5.
Then, select a folder to save your application in or create a new folder. Select “Next

Step”.
6.
F
ill out the rest of the account details including subdomain name, shell username, and

setting a Drupal administrator password as shown below:
7.
C
lick “Next Step” and on the next page you will see a page that tells you all the account

details you need to access your new site!
Take a screenshot of this page if you want to

remember all of your passwords (you can reset them later if you need t
o
).
8.
Finally
select “Create my new site”.
Your site will be completely configured for Drupal, including the settings.php file, directory

and file permissions, and cron. You will receive an email with a link to access your configured

application.
This final step can take 10-20 minutes.
If you’d like to password protect your site
from other people seeing it
while it is under

development, simply click on Web Access Lock
from your WebEnabled account
, and you will

be prompted to set a password.
You can access your WebEnabled site in several ways – through Drupal’s interface for

configuring your site and adding content, over SSH for command-line access to the server,

through SFTP for uploading/downloading files, and using SVN for version control.
Please check out WebEnabled’s excellent articles and videos for tutorials on how to use these

features:
http://www.webenabled.com/how-it-works
.
Site Clones
Every month you will get a new “clone” of the sample site of the month. This site is pre-built

for you. No additional work is required on your part. Think of this site as the “answers” for the

workbook. Use this clone to see if you're doing things “right.”
The details for the clone may be delivered as a URL, or via email.
If you get a URL
, click on the link and complete the steps to create your clone as described

in the section on one-click installs via the WebEnabled Marketplace.
If you get an email
, click on the link in the email and log into your WebEnabled account (if

you don't have one yet, you will need to create one before you can proceed).
1.
Once logged into your account, click on the tab labeled, “Overview.”
2.
On the right hand side you should see a box for “System notices.” There will be a

notification that a new application has been shared with you. Click on the link

labaeled “Start your own copy.”
3.
Proceed with the instructions for one-click installs via the WebEnabled

Marketplace.
Working with Sites on WebEnabled
Drupal is designed to run several Web sites from the same set of base files. This is referred to

as a
multisite installation
. Nearly all of my small business sites are hosted this way. The

advantage is that I can perform fewer security updates because I'm only updating one set of

files instead of having to work with each site individually. The disadvantage is that if I make a

mistake in one place during an upgrade, all other sites
may
be affected too.
For this course I recommend you work on only one site at a time on WebEnabled—not

multisite. This means more practice installing modules (when we get there) and less risk of

things going really wrong and wrecking perfectly good sites. Later in the program you'll learn

how to package up functionality so that you can replicate functionality on multiple sites (we'll

use the Features module for this).
DIY
Installation
Proceed with the following instructions if y
ou’ve opted to install Drupal yourself
instead of

using WebEnabled.
For these instructions you will need to know three things: that your Web

server meets the minimum requirements to install Drupal, how to create a database and

where to upload Drupal’s files to. If you aren’t sure about this information ask your hosting

provider for help.
Minimum Requirements
The following are required to run Drupal:

Apache 2 or greater running on Windows, Mac OSX or Linux. IIS is also supported

when correctly configured. If you are choosing your hosting opt for Apache 2 on Linux

if possible.

MySQL 5.0.15 or higher, and requires the PDO database extension for PHP (see PHP

section below)
or
Postgres 8.3 or greater. Instructions on configuring Drupal with

Postgres are not covered in this book.

PHP 5.2 or higher with a
minimum
memory allocation of 64 MB and support for the

GD Image Library enabled. Note: Most shared hosting providers set the memory

allocation to 16M by default.
The detailed list of requirements is available at
http://drupal.org/requirements
.
Creating a Database for Drupal
Drupal stores your content and its configuration options in a database--you will need to create

a database for Drupal before beginning the installation process. Depending on your hosting

provider there are three ways to create a database (choose the one that applies to you):

through your hosting provider’s administrative panel

using the database configuration tool PhpMyAdmin.

from the command line on Linux or Unix-based systems
XAMPP and MAMP ship with phpMyAdmin pre-installed. Most hosting providers will also

have it installed, unless they have their own configuration system for creating new databases.
When you create the new database you may be asked which character set you would like to

use. Choose UTF-8.
Jot down the name of the database, its username and password. You will need this

information to complete your Drupal installation. Take note of the server name as well. It will

either be “localhost” or something else.
Preparing the Drupal Files for Installation
Drupal the product is a series of PHP files (and one server configuration file). To install

Drupal you will need to put these files in a folder that your Web server can find.
Tip: An FTP client is essential for installing Drupal
If you are doing your own installation of Drupal you will need an FTP

client to put Drupal’s files onto your Web server. FileZilla is a free

program that can be used on Windows, OSX and Linux. You can

download it from http://filezilla-project.org/download.php.
Complete the following steps to prepare Drupal’s files for installation.
1.
Download Drupal.
Go to drupal.org look for the download section on the front page.

Click on the option for “Drupal 7.” An archive package of all the files you need should

automatically begin downloading to your computer.
2.
Move the files to the appropriate directory
: Unpack the downloaded archive file.

Copy the contents of the folder to the document root for your Web server. Be sure to

copy the hidden file .htaccess too. It is in the main Drupal folder.
3.
Create a settings file for your installation.

Navigate to the Drupal folder

sites/default
. Make a copy of the file
settings.default.php
in the same directory.

Name the new file
settings.php
.
4.
Adjust the permissions on the file settings.php.
The settings file will need to be

readable and writable by your Web server so that it can be updated during the

installation process. Using your FTP client, set all access permissions to “Read &

Write.”
5.
Adjust the permissions on your site’s settings folder.
The folder which

contains your settings file will also contain a number of folders to store uploaded files,

themes and site-specific contributed modules. You must allow your Web server

permission to read the contents of, and create new files within, this folder. Locate the

folder
sites/default
. Modify the settings so that the folder is read-write-executable by

your Web server. This user name will depend on your hosting configuration. Typically

setting the “owner” and “group” to “Read & Write & Execute will be sufficient.
You will know if you have prepared your server correctly if you are able to complete Drupal’s

install wizard without any errors. If you do get errors read the message carefully and complete

the on-screen instructions to fix any problems that arise. Specific trouble-shooting tips are

also available from Drupal’s Installation Guide (
http://drupal.org/getting-started/install
).
Tip: Keeping your site secure
Once your site is up and running you should lock down write permissions

so that only the folder
sites/default/files
can be written to. Your Web

server only needs “Write permissions” to the modules and themes folders

if you are adding new modules or new themes. Once your site is

configured properly you can disable write permissions from these two

folders.
These instructions assume you will only be installing one Web site per set of Drupal 7 files.
Multisite
Sometimes it makes more sense to set up multiple instances of Drupal from the same set of

files. For example: my laptop is set up to do a fresh installation of Drupal each time I give a

presentation so that there's always a “clean” version to work from.
It's very easy to set up a new Web site from the same code base.
1.
In your sites folder, create a new folder with the domain name you want to use. For

example: mysandbox.com.
2.
Check the permissions on the new folder to ensure your Web server has read-write-
execute access to the folder.
3.
Copy the default settings file from the folder
sites/default
into your new folder.

Make sure it is named
settings.php
and is readable and writable by the Web server.
4.
In your Web server configuration panel point the new domain name to the main

Drupal folder. For example:
/home/d7sbe/public_html
,
not

/home/d7sbe/public_html/sites/domainname.com
. Drupal will figure out

which folder you really mean.
5.
Proceed with the installation as if you were creating a new Drupal site. Navigate to the

domain name and complete the installation wizard.
Check the URL as you are doing the installation to ensure you are using the right domain. If

something has gone wrong you may be redirected to a different domain name.
Sandboxes for Testing and Demonstrations
F
or local sandbox sites I find it's easier to put each installation into a sub-folder
so that I don't

have to set up a new sub-domain for every sandbox I want to work on
. To replicate this setup

name your sites with the folder name
after
the local domain name. For example: if the base

URL is
http://mysandbox.com/site1
, the folder name is
sites/mysandbox.com.site1.
The only gotcha is that you have to put a symlink in the
main Drupal
directory to the name of

the folder
that was tacked onto the end of your URL in the sites folder. For example, if your

URL was going to
:
$ ln -s . your_folder_name
If you're going to be doing a lot of demos, I also recommend the Demo module

(
http://drupal.org/project/demo
). This module allows you to dump work that's been done on

the site and revert back to a previous state.
Working with an empty site makes it hard to see how content will behave within your design.

If you don't feel like typing out your own words, you can have content automatically generated

for you. Here are a few of my favorite ways to do it:

Find a Gutenberg book and copy its pages into your site (
www.gutenberg.org
).

You can also wrap Gutenberg books in HTML with Fillerati

(
http://www.fillerati.com/
).

Use the Devel Generate module to generate content, menu items, taxonomy terms and

users (
http://drupal.org/project/devel
).

Use the Firebug add-on Dummy Lipsum (
https://addons.mozilla.org/en-
US/firefox/addon/dummy-lipsum/
).
I'm sure there are at least 100 more ways to do the tedious task of adding fake content into

your Web site,
but hopefully at least one of these suggestions was new to you.
Drupal’s Install Wizard
Assuming your server is correctly configured, it is very easy to install Drupal. You will be led

through a series of screens which prompt you for information about your database and which

help you to create a maintenance account.
In a Web browser, navigate to the URL which holds your Drupal files. For example:

http://mywebsite.com/drupal
or just
http://mywebsite.com
. Drupal will automatically

recognize that you want to install Drupal. Your first step is to choose the Install profile you

would like to use.
L
eave the selection at “Standard” and click “Save and continue” to proceed.
By default there is only one language option available for Drupal: English. If you wish to

install Drupal in a different language, click the link “Learn how to install Drupal in other

languages” otherwise click “Save and continue” to proceed to the next step.
On the third configuration screen you will be prompted for your database information.
Enter

your database name, database user name and password. If your database host name is

something other than “localhost” click the advanced link and complete the inset image portion

of the form.
With your database information entered, click “Save and continue” to install Drupal. Figure

5.5 shows the status bar that will appear as your Drupal installation is automatically

configured. Depending on the speed of your Web server this may take up to 30 seconds. Do

not close the browser window. Wait patiently while Drupal installs itself.
Once Drupal is installed you will need to create a site maintenance account and configure

some basic administrative settings.
The
site configuration screen
is shown below
.
Complete each section using the most appropriate options for your Web site:

Site name
will be displayed in the header of your Web site. Use your business name if

you are creating a business Web site.

Site email address
. Use your email address.

Site maintenance account
user name, email address and password. By default Site

email address is used. You may change this to a different address if you would like.

Server settings
are not required, but they will be used to time-stamp your blog

entries and other content creations.

Update notifications
allow Drupal to check in with the mothership and send you an

email whenever a security release, or new version of your installed modules are

available. Leave these settings as-is unless you are running a development Web site

that is not exposed to the Internet.
These settings can all be changed from the administrative area.
Drupal is now installed and configured for basic use. You will be redirected to the front page

of your Web site.
Administering Drupal
In every Drupal installation there is both a
public
version of your Web site and a private,

administrative area. Once you’ve entered your user name and administrative password you

will have access to the screens described in this chapter.
Drupal focuses on the ability to edit configuration options in place
. It uses both a public theme

(design) and also an administrative theme that you will use when editing content. Once you’ve

logged into your site you will see a set of toolbars appear across the top of your site. These

toolbars are only visible to authenticated users.
There are four parts to the administrative interface that you need be aware of.

The
Overlay
allows you to edit content, administer modules and do just about any

other administrative task without leaving your current page.

The
Toolbar
is visible across the very top of your Web site. It lists the main sections of

the administrative area and provides a link to your account and an option to log out of

the Web site. It cannot be customized.

Shortcuts
are available directly beneath the toolbar. This is a list links within your

Web site that you would like to have available. You may use the default administrative

links, or create a personal set of short cuts.

The
Dashboard
provides you with a summary of what’s happening on your Web site.

It can be configured to display any available blocks for your Web site.
The numbered areas on this screen shot represent the Toolbar (1), Shortcuts (2), Dashboard

(3) and Overlay (4) (white screen with black background which appears “over” the Drupal

contents):
Administrative Overlay
Hopefully the overlay needs no explanation. It allows administrative changes to be made to

the site without losing the context of the current page. The addition of the overlay means you

can easily cancel any administrative changes and return to the page you were previously

viewing. The overlay is also used when creating new content.
The entire administrative theme is also available without the overlay. This
program
will use

screen shots featuring the administration theme Seven with the overlay turned
on
; however,

you may choose to disable the overlay by
completing the following steps:
1.
On the top of the screen is a black administrative tool bar. Locate and click on the link

for “Modules.”
2.
Scroll to the Core section and locate the Overlay module. Unselect the check box beside

the Overlay module.
3.
Scroll to the bottom and click “Save configuration.”
The overlay will now be completely disabled.
Administrative Toolbar
The administrative toolbar provides links to the eight main sections within the administrative

area of the site. Throughout this book you will use these links to configure your Web site.

When the instructions tell you to select a menu item from the toolbar, it is referring to this list

of options. You may choose to explore each of these options now, or wait for the menu

contents to be revealed as-needed.

Content
Administer content you have created and comments that visitors have left on

your Web site. Chapter 14 will cover content management in greater detail.

Structure
To administer menus, content types and blocks (the stuff that shows up in

sidebars) you will use the Structure menu. Options available in this menu will be

covered in more detail in Chapter 7.

Appearance
Don’t like the way your site looks? Learn how to change how things look

in Chapter 8.

People
Most basic Web sites are managed by a single person. When your team grows

larger, or if you have a community site where you have multiple participants, you will

spend a lot of time in this area of the administrative section. Skip ahead to chapter 15 to

learn more about User Management.

Modules
Drupal itself is a pluggable architectural framework. It allows you to plug in

new functionality. In the next chapter you will learn how to select and install modules.

Configuration
Remember how I promised that you would be able to change any of

the settings you chose during the installation? If you want to, this is the menu item

you’ll need. The Configuration menu is also the home for default account settings

(more in Chapter 15) and site-wide searching (Chapter 12).

Reports
Drupal comes with some basic reporting tools. From this menu option you

may view reports, site errors and available updates. You will learn more about this

section in Chapter 13.

Help
Need I say more? Sometimes we all need a little more help. Go here to find out

more about modules in your system and some of the interface components in Drupal.
The menu items Content, Structure, Appearance, People and Modules will be covered in

subsequent chapters. Configuration, Reports and Help are covered in this chapter.
Administrative Shortcuts
Ever notice there are some things you do more than anything else in your Web site? The

administrative shortcut menu (located directly beneath the toolbar) allows you to easily add

shortcuts of
your choice
to the administrative interface.
At any time you may add items to the shortcut menu by navigating to an administrative page

you would like to add to the shortcut menu and clicking the + symbol beside the title page.

Once added the symbol will change to -. To remove an item from the shortcut menu, click the

- symbol as shown in Figure 6.3 beside the title “Content.”
To configure all shortcuts, click on the link towards the top right of your screen labeled, “Edit

shortcuts.” An administrative overlay will appear as shown
below
. From here you may add,

modify and delete shortcuts. To add a new shortcut click the link “Add shortcut.” A new screen

will appear. Add the name and Drupal path for the shortcut you want to add.
By default Drupal provides a global shortcut menu which is available to administrative users.

You may create additional shortcut menus which are available to some, or all, users. By

default authenticated users are not allowed to view or edit the shortcut menu.
Hiding the Shortcuts
If you want you can also hide the shortcut menu. On the far right of the menu is a little arrow

pointing down. To hide the shortcut menu click the arrow and the shortcuts will snap out of

view. To reveal the shortcut menu, click the arrow again and the menu will snap back into

view.
Administrative Dashboard
Drupal allows you to completely customize the main administration page using blocks. In

addition to the blocks created by modules, a new block is created for each new menu you

create. You will learn more about creating menus in the next chapter.
Tip: Drupal blocks
A Drupal block is equivalent to what other content management systems

sometimes call a “widget.” It is a small unit of functionality prepared by a

module and which can be displayed anywhere on your site. Common

blocks include: search, user login and recent comments.
Your administrative dashboard should be customized to include information that is useful to

you.
For inspiration on what to put into your dashboard, check out the Total Control module by

Jen Lambton. Even though it uses the Panel module for layout, the project page gives great

ideas about the kind of information you may want to summarize for administrative users. The

Total Control module is available from:
http://drupal.org/project/total_control
.
Configuration
To alter the site-wide settings for your Web site click on the link, “Configuration” from the

Admin Toolbar. You will be presented with an extended version of
the image below
.
Groups of

configuration options include: People, Content Authoring, System, User interface,

Development, etc.
As you install new modules additional configuration options may become available on this

screen. For example under section heading “User Interface” there is a link for “Menu Block.”

This is a contributed module that is not available in the default installation of Drupal.
At this point you should familiarize yourself with three configuration screens:

Configuration, System, Site information.

Configuration, Regional and Language, Regional settings.

Configuration, Regional and Language, Date and time.
Site Information
There are two different configuration options available from the System heading: Site

information and Actions. We will focus on Site information in this chapter. Actions, which

allow you to automate tasks, will be covered in Chapter 14. Navigate to the Site information

configuration screen. It can be accessed at any time from the Admin Toolbar by selecting,

“Configuration” and then “Site information.”
The Site Information configuration screen allows you to customize the following:

Site name.
The name of your site is included on all page titles. The theme for your site

will typically also display the Site name in the top left corner of each Web page.

Slogan.
A sub-title for your site. Depending on your theme this will display beside or

beneath the Site name. The slogan does not typically appear in the page title.

E-mail address.
Used by system messages such as automated emails sent during the

registration process.

Default front page.
By default this is set to “node” which will publish any piece of

content that has been flagged as, “Promoted to front page.”

Number of posts on front page.
This number also controls the number of items

that will appear per “page” of results when there are more than the set number of posts

available (for example: if you have 20 posts there will be two pages of ten posts each).

Default 403 (access denied) page.
When site visitors do not have sufficient

permissions to access a page they will see a generic “access denied” message. This

setting allows you to customize the page that is displayed.

Default 404 (not found) page.
When site visitors arrive at a URL on your site that

does not exist they will see a generic “page not found” message. This setting allows you

to customize the page that is displayed.

Automatically run cron.
Certain features within Drupal need to be updated on a

quasi-regular basis. This setting adjusts how often these tasks are performed. For

example: indexing new content that has been added to your site for Drupal’s built-in

search engine.
Additional display options, such as the site logo and colors, are adjusted from within the

theme.
Theme Configuration
Blue is nice. The Drupal mascot, Druplicon, is great. But the default theme says something

about Drupal, not about you. Let’s
adjust the default theme, Bartik, to make
your site reflect

you. With a few quick changes to your site you can turn the default theme into one that

reflects who you are.
Assuming you've just installed Drupal and you've made no additional

changes, you are currently using the theme, Bartik.
Adding a Site Logo
The default logo is the Drupal mascot, Druplicon. To replace this icon with your own image

complete the subsequent steps. Your new logo will not be resized by Drupal. Make sure it’s the

right size before you upload the image.
1.
From the Administrative toolbar click on “Appearance.” For the theme labe
l
led “default

theme” find and click on the link titled, “Settings.”
2.
Scroll down to the section titled, “Logo Image Settings.” Deselect the checkbox label
l
ed,

“Use the default logo.” A new configuration screen will appear.
3.
To upload an image from your computer, click the button “Browse...” You will be

prompted to locate an image from your computer to upload. Select the image and click

“Open.” (The text may differ slightly for different Web browsers.)
4.
Scroll to the bottom of the configuration screen and click, “Save configuration settings.”
Your new logo will now appear in the top right of the page.
Tip: Change your Shortcut “favicon” too.
By default the Druplicon will also appear as your site’s Shortcut icon. You

may change this to a different image from this configuration screen or

choose to omit it by deselecting the checkbox for the “Shortcut icon.”
Adjusting the Colors
With your logo uploaded to the site you may want to adjust the main colors of the Web site

too. Use the following steps to re-color the default theme, Bartik. (I suppose I could insert

screen shots here, but this is a black-and-white book and … well.. you’d just get the same thing

but in two shades of gray. It seems like a waste of ink so I ask you to use your imagination

instead. How about I make it up to you with a picture of a kitten? Please see Figure 7.2.)
1.
From the Administrative toolbar click on “Appearance.” For the theme labeled “default

theme” find and click on the link titled, “Settings.”
2.
If you uploaded a new logo in the previous step you will now see a preview of your site

including your logo. You may need to scroll down a bit to see the Preview.
3.
Adjust each of the colors according to your needs. There are several color sets available

for you to pick from. These color sets are high contrast and accessible to all Web site visitors.
4.
When you are happy with the Preview, scroll to the bottom of the configuration screen

and click, “Save configuration.”
Your site has been magically re-colored and a
new logo
has appeared.
Your site may now look

something like this:
Date, Time and Regional Settings
Now that we’re in the space age your Web server may not be in the same time zone you.

Fortunately Drupal allows you to perform a little time travel and set the right time for your

Web site. These settings can be configured from Configuration, Regional settings. From this

screen you can configure:

Default country.

First day of the week.

Default time zone.
You may also allow users to set their own time zones. This setting is only relevant to multi-
user, high traffic sites.
In addition to the timezone, you can also customize how the dates are displayed on your site.

Navigate to Configuration, Date and time to configure these settings.
Most themes will use the Medium format Date type for date stamps that appear on posts.

Support for custom
Date types
is not universal. If you need to adjust the formatting of dates

on your site you are better off to assign a custom
Date format
to one of the existing Date

types.
If you want to
only the date (remove the
time
)
on your blog posts you can write a custom date

format using the following steps:
1.
From the Date and time configuration screen, click on the “Formats” tab on the top

right of the overlay.
2.
Click on the link labeled, “Add format.”
3.
In the resulting form add the PHP date constants for the format you want to create. A

sample will be displayed to the right of the form field.
A list of commonly used formats

is available after this set of instructions.
4.
Click “Add format” when you have the entered the desired date output. On the top right

of the overlay, click “Types.”
5.
Next to the appropriate Date type choose your new format from the drop down box.

Click “Save configuration.” Your new date format will be applied immediately

throughout the site.
Format

character
Description
Sample output
d
Day of the month with leading zeros.
01 to 31
j
Day of the month without the leading zeros
1 to 31
S
English ordinal suffix for the day of the month.

Sample output is shown as
jS
.
1st, 2nd
D
Three letter textual representation of the day of the

week.
Mon, Tue
l
(lowercase

L)
Full textual representation of the day of the week.
Monday,

Tuesday
m
Numeric representation of the month with leading

zeros.
01 to 12
n
Numeric representation of the month without leading

zeros.
1 to 12
M
Three letter textual representation of the month.
Jan, Feb
F
Full textual representation of the month.
January
y
Two digit representation of the year.
99 or 10
Y
Four digit representation of the year.
1999 or 2010
You may also add punctuation to your format. For example:
[lb]
F j ‘y
would display as
August 26 ‘10
.
[lb]
Y-d-m
would display as
2010-08-26
.
[lb]
F jS, Y
would display as
August 26th, 2010
.
[lb]
l F jS, Y
would display as
Thursday August 26th, 2010
.
A complete date format reference, including time formats, is available online at

http://php.net/manual/en/function.date.php
.
Administrative Reports
Drupal provides some basic reports that you should familiarize yourself with. These reports

will let you know about the health of your Drupal installation. You should get into the habit of

checking these reports to ensure your Drupal installation has all of the latest security patches

applied. Unlike the announcements song from camp (You know the song, right? With the

bologna and the cow? No? A very excellent guide is available from

http://www.youtube.com/watch?v=ML2NHsexzb0) these reports are actually useful. No bull.
From the Reports tab in the Administrative toolbar you can access the following information:

Status report.
Provides a summary of the health of your Drupal files including

protection of specific files, and required PHP modules. If something new that you’ve

installed isn’t working look here.

Available updates.
Informs you when Drupal and contributed modules are out of

date. This report can be configured from the settings tab at the top right of the

Administrative overlay. Figure 6.8 provides an example of Drupal core that is out-of-
date and an up-to-date module.

Recent log entries.
Recent actions taken on your site. For example: new pages

added, user logins, pages updated, user created.

Top “access denied” errors.
URLs commonly visited by non-authenticated users.

Entries are added to this report when someone tries to visit a page that exists, but is not

within their level of security clearance.

Top “page not found” errors.
URLs commonly visited which do not have a

corresponding Drupal page.
Help
Every Drupal module comes with a basic set of instructions. Or perhaps that should read:

every
good
Drupal module comes with a set of basic instructions. These instructions are

available from the Help tab in the Administrative toolbar. Figure 6.9 shows the help page for

the Node module. As you can see there are three sections: About, Uses and links to relevant

administration pages.
The help pages are intentionally sparse. Where possible they link to relevant pages within the

relevant handbook page on Drupal.org where community members can update and enhance

the instructions.
T
he corresponding online handbook page for the Node module

(
http://drupal.org/handbook/modules/node
)
is shown below
. Note the related content on the

left side of the screen shot.
About The Author
Emma Jane Hogbin (drupal.org user emmajane) is an internationally

renowned technical author and trainer who specializes in teaching people,

just like you, to make beautiful Web sites. Emma's first book,
Front End

Drupal
, is recognized in the industry as the most important book for

Drupal designers. She has been teaching internet technologies since 2002

and has been building Web sites for over ten years.
A
frequent speaker at technical conferences in Canada, the US and Europe

and
Emma
also likes single malt whiskey. These two things are probably

not related.
Her presentations have taken her to France, Belgium,

Hungary, Canada, New Zealand, England and the United States. In

addition to her engaging conference presentations, Emma has also worked

as a technical college instructor at Humber College and Seneca College,

and has worked on curriculum development for Humber College and the

Ubuntu Linux distribution.
Emma encourages non-traditional participation in technology through

craft and believes that everyone is capable of mastering the tools that surround them. To help

engage new ways of participating in technology, she open sourced one of her knitting patterns

so that you can make your very own
Drupal Socks
(as featured in
CRAFTzine
).
She is the

recipient of the Google Diversity Award for helping to encourage women in technology and is

the sponsor of Creative Use of Technology
which is awarded every year to a female student at

West Hill Secondary School in Owen Sound, Canada
.