an introduction to drupal

63
An Introduction To Drupal

Upload: tobias-ratschiller

Post on 28-Jan-2015

6.271 views

Category:

Technology


1 download

DESCRIPTION

Are you looking at Drupal as your new CMS? This presentation gives an overview of Drupal and some common use cases. Targeted at IT managers looking to chose a new CMS or who just want to get more familiar with Drupal.

TRANSCRIPT

Page 1: An Introduction to Drupal

An Introduction To

Drupal

Page 2: An Introduction to Drupal

What? Who? This is an overview of Drupal and some common use cases. It‘s mainly intended for

• IT managers or consultants tasked to choose a new CMS.

• Editorial and technical staff getting acquainted with Drupal.

• Anyone looking for a summary of Drupal.

The origin of this presentation is a consulting engagement at the European Institute for Gender Equality, an EU organization based in Vilnius, Lithuania.

Page 3: An Introduction to Drupal

About Me

• Tobias Ratschiller

• Working the Internets since almost

15 years.

• Wrote Web App Development with

PHP in 2000, initial versions of

phpMyAdmin, phpAds (openX), using

Drupal since 2005.

• Now owner of a small company,

runing many sites on Drupal,

2.5million uniques per month.

Page 4: An Introduction to Drupal

About Me

For example, Denmark.net

• 424,000 nodes

(„pages“).

• High traffic.

• Business directory, jobs,

events, forums, weather,

hotels, blog.

Page 5: An Introduction to Drupal

Drupal 101 – What is Drupal?

Drupal allows you to easily publish and

manage a wide variety of content on a

website.

Hundreds of thousands of people and

organizations are using Drupal to

power an endless variety of web sites,

including

• Community web portals.

• Intranet applications.

• Personal web sites or blogs.

• E-commerce applications.

Page 6: An Introduction to Drupal

Drupal 101 – What is Drupal?

• Open Source project

created by Dries Buytaert in

2000.

• Supported by a community

of over 400,000.

• Commercial support

available via Dries‘

company Acquia and

others.

http://www.flickr.com/photos/35034362831@N01/2660877655

Page 7: An Introduction to Drupal

Drupal 101 – Open Source

• Drupal is released under

the GPL, version 2.

• You can download, reuse,

modify, and distribute it.

• If you distribute derivative

work (modules, themes,

etc), the same terms have

to be applied.

Page 8: An Introduction to Drupal

Drupal 101 – Community

• Large community - Drupal is

easy to get started with.

• Drupal.org/forum for

support, finding developers

and designers.

• Elance, Freelancer.com

have many Drupal-skilled

professionals.

• Contribute yourself -

modules, themes, bounties,

sponsorships.

Page 9: An Introduction to Drupal

Agenda – Drupal in Real Life

• Setup

• Create a page

• Create a blog

• Change layout

• Install modules

Page 10: An Introduction to Drupal

Drupal in Real Life - Setup

Setting up a Drupal website

(Unix/Linux):

1. Download from drupal.org to

your server.

2. Create DB.

3. cp sites/default/default.settings.php sites/default/settings.php

4. chmod 666 sites/default/settings.php

5. Go to the home of your website

and finish the install script.

Page 11: An Introduction to Drupal

Drupal in Real Life - Setup

Setting up a Drupal website

(Windows):

One-click install through the Acquia

Drupal Installer

(http://acquia.com/downloads).

Includes all components (Apache,

PHP, MySQL, phpMyAdmin) to get

up and running with a single

installation.

Page 12: An Introduction to Drupal

Drupal in Real Life - Setup

Drupal 5.x Drupal 6.x Drupal 7

Status Outdated Current Coming late 2010

Support Legacy support (bug

fixes)

Supported (bug

fixes, small feature

enhancements)

Not supported for

production

Recommended For legacy

applications

Choose this for new

sites going online

2010

Choose for sites

going online 2011

Major versions (5, 6, 7) are released every 12-24 months.

When choosing Drupal, you should plan a major update to your

site every 24 months at least.

Page 13: An Introduction to Drupal

Real Life - Create a Page

1. /node/add/page

2. Enter title.

3. Enter menu name.

4. Enter body.

5. Submit!

Page 14: An Introduction to Drupal

Real Life - Create a Page

Page 15: An Introduction to Drupal

Real Life - Create a Blog

1. Make sure the „blog“ module is

enabled (in Administer -> Site

Building -> Modules).

2. /node/add/blog

3. Enter title and body as before –

no menu entry necessary.

4. Blog posts are published to the

front page by default.

Page 16: An Introduction to Drupal

Real Life - Create a Blog

Page 17: An Introduction to Drupal

Real Life - Create a Poll

1. Make sure the „poll“

module is enabled (in

Administer -> Site Building

-> Modules).

2. /node/add/poll

3. Enter title and choices.

4. Poll is published to

frontpage by default.

Page 18: An Introduction to Drupal

Real Life - Create a Poll

Page 19: An Introduction to Drupal

Real Life – Change Layout

• Layouts/styles are called

„themes“ in Drupal.

• To change, go to Administer

-> Site Building -> Themes.

• Chose any theme there as

enabled and default.

Page 20: An Introduction to Drupal

Real Life – Reorder Site Elements

Drupal themes define site elements,

for example a sidebar or the footer.

These elements are known as

„blocks“.

Modules expose snippets that can be

shown in blocks. For example, the

„blog“ module has a block showing the

latest blog entries.

Go to Administer -> Site Building ->

Blocks to set up blocks.

Page 21: An Introduction to Drupal

Real Life – Change Layout

Before

Page 22: An Introduction to Drupal

Real Life – Change Layout

After

Page 23: An Introduction to Drupal

Real Life – Change Layout

Where to find themes?

• Drupal.org

• Themegarden.org

How to install themes?

1. Download and extract to

sites/all/themes.

2. Enable via Administer ->

Site Building -> Themes.

Page 24: An Introduction to Drupal

Real Life – Change Layout

• Layouts/styles are called

„themes“ in Drupal.

• To change, go to Administer

-> Site Building -> Themes.

• Chose any theme there as

enabled and default.

Page 25: An Introduction to Drupal

Real Life – Reorder Site Elements

Page 26: An Introduction to Drupal

Real Life – Reorder Site Elements

Page 27: An Introduction to Drupal

Real Life – Install Modules

Modules extend Drupal‘s

functionality.

Over 2,000 modules can

be downloaded from

Drupal.org.

Place into

site/all/modules, enable

in Administer -> Site

Building -> Modules.

Page 28: An Introduction to Drupal

Agenda – How To

• Prevent spam

• Resize photos

• Add a forum

• Add a job board

• Add an event calendar

• Add a photo gallery

• Add a newsletter

Page 29: An Introduction to Drupal

How To – Prevent Spam?

• Mollom by Acquia/Dries – an all-in-one solution to combat

spam. Three subscriptions: free, 30 Euro/month/site, 3,600

Euro/year/site

• Or roll your own:

„spam“ module

image captcha

comment notification

Page 30: An Introduction to Drupal

How To – Prevent Spam?

Spam module

• Checks comments (and optionally other content).

• Shows potential spam on Administer -> Content management -

> Spam.

Page 31: An Introduction to Drupal

How To – Prevent Spam?

CAPTCHA module

• Different flavors of captchas: text, image, quiz.

• Captcha can be shown on user signup, login, comments, etc.

Page 32: An Introduction to Drupal

How To – Prevent Spam?

Comment notification

• Administrators should get notified when a new comment is

posted.

• Drupal 6.x can do this with triggers and actions.

1. Enabled trigger module.

2. Create a new action

„Send e-mail.“

3. Associate with

trigger „New

comment

notification.“

Page 33: An Introduction to Drupal

How To – Resize Photos?

Imagecache module

• Automatic actions for uploaded images, for example resizing

or watermarking.

• Perfect for standardizing sizes for embedded photos.

Page 34: An Introduction to Drupal

How To – Add a Forum?

Forum module

• Make sure the module is enabled.

• Go to

admin/content/forum/add/container,

enter name.

• Go to

admin/content/forum/add/forum,

enter name.

Page 35: An Introduction to Drupal

How To – Add a Forum?

Page 36: An Introduction to Drupal

How To – Add a Forum?

Advanced Forum

module

• More advanced

like a real forum.

• Typical forum

homepage, avatars

in posts, private

messages, etc.

• All-in-one install.

• But: Alpha

Page 37: An Introduction to Drupal

How To – Add a Job Board?

• There really is no good out of the box job

board for Drupal:

– Be prepared for some custom dev.

– Or choose a third party board.

• Try the job_posting or job_search modules.

– Jobs can have expiration, location,

categories, multiple employers.

– Users can apply and send their resumes

as attachments.

Page 38: An Introduction to Drupal

How To – Add a Job Board?

Page 39: An Introduction to Drupal

How To – Add an Event Calendar?

Calendar module

• Very flexible module to create any

calendar-based view you would ever

want.

• Based on Views. Views are Drupal‘s

way to create complex pages. It‘s like

a query builder.

• To install the module,follow the quick

and easy 31-step procedure:

http://drupal.org/node/797042

Page 40: An Introduction to Drupal

How To – Add an Event Calendar?

Page 41: An Introduction to Drupal

How To – Add a Photo Gallery?

Image and Image_Gallery modules

• Creates thumbnails to be

shown on gallery.

• Easy to set up: install

module, create album.

Page 42: An Introduction to Drupal

How To – Add a Photo Gallery?

Page 43: An Introduction to Drupal

How To – Add a Newsletter?

SimpleNews module

• HTML and plain text newsletters.

• Users can subscribe and

unsubscribe.

• Web archive available.

Page 44: An Introduction to Drupal

Agenda – Running Drupal

• Backups

• Updates

• Monitoring

• Deployment

• Security

• Performance

Page 45: An Introduction to Drupal

Running Drupal - Backups Backup and Migrate module

• Backup DB and files to server, FTP, Amazon S3 or

email.

• Create automated schedules.

• Great for small,

non-critical sites

with no uptime

or performance

guarantees.

Page 46: An Introduction to Drupal

Running Drupal – Updates

Updating Drupal

• Minor versions (eg 6.10 to 6.11):

– Manual process to download new version

and copy it over.

– See http://drupal.org/upgrade

• Every 12-24 months: major upgrade.

Page 47: An Introduction to Drupal

Running Drupal – Updates

Update modules

• The update module checks for newer versions

of Drupal and installed modules.

• To update a module:

1. Download new version.

2. Remove old module code, copy updated.

3. Run /update.php.

Page 48: An Introduction to Drupal

Running Drupal – Monitoring

• The Acquia Network comes with rudimentary

monitoring (heartbeat and email notification).

• Alternatively install own monitoring or

subscribe to pingdom etc.

• Keep an eye on /admin/reports/dblog.

Page 49: An Introduction to Drupal

Running Drupal – Deployment

Typically, small setups

use a local development

environment and a live server.

For larger setups, a typical

scenario is

• Version control (SVN etc)

• Live server

• Staging server

• Dev server or local dev servers

Page 50: An Introduction to Drupal

Running Drupal – Deployment

The problem is the

database:

• Content from live has to

be brought to staging/dev.

• One strategy is daily import

of parts of the live DB (eg

import nodes, but don‘t import

live user data, sessions, billing data).

There is no out-of-the-box solution.

Page 51: An Introduction to Drupal

Running Drupal – Security

Most security problems come from the

system, custom code or contributed

modules, not from Drupal core.

• Keep Drupal up to date, pay special

attention to security updates.

• Have good system administration

processes.

• When writing code, follow

http://drupal.org/writing-secure-

code

Page 52: An Introduction to Drupal

Running Drupal – Performance

Drupal, by default, is resource intensive.

• Many database queries.

• The more modules, the slower.

• Easy to write sloppy code.

But: Drupal performance is largely a solved problem.

• Use a PHP cache. enable Agressive Caching, Block Cache,

custom cache.

• Lots of anonymous traffic? Consider the Boost module.

• Split DB/webserver. Examples available on Drupal.org.

Page 53: An Introduction to Drupal

Agenda – Grown Up Drupal

• Editing

• Multilanguage

• On Site SEO

• Workflows

• Acces control

• Extending

Page 54: An Introduction to Drupal

Grown Up Drupal - Editing

Wysiwyg module

• Adds visual text editors to text area fields.

• You can chose from different editors.

• TinyMCE is probably most common.

Page 55: An Introduction to Drupal

Grown Up Drupal - Editing

Page 56: An Introduction to Drupal

Grown Up Drupal – Multilanguage

Drupal 6.x + i18n module + Translation Management module provide everything that is needed for multilingual websites:

• Out of the box translations for the system.

• Web interface to add translations.

• Central overview of content that needs to be translated.

Page 57: An Introduction to Drupal

Grown Up Drupal – On Site SEO

• Pathauto module: Creates path like /this-is-a-test.html instead

of /node/14.

• Global Redirect module: Makes sure content is only available at

one location (for example, /node/14 redirects to /this-is-a-

test.html)

• Path Redirect module: Redirects old paths to new paths. For

example, when you change the title of the node, /this-is-a-

test.html redirects to /this-is-the-new-title.html .

Page 58: An Introduction to Drupal

Grown Up Drupal - Workflows

Roles and permissions

• Users can have roles, such as

„author“ or „editor.“

• Roles have permissions, such as

„create page content.“

• All functionality that is not

explicitely allowed is hidden.

Page 59: An Introduction to Drupal

Grown Up Drupal - Workflows

Workflow module

• Defines editorial processes, for example:

– Author writes article as draft.

– Editor is notified via email.

– Editor approves the article, publishes.

• Flexible, for example define an action to reject a draft and notify author.

Page 60: An Introduction to Drupal

Grown Up Drupal - Workflows

Page 61: An Introduction to Drupal

Grown Up Drupal – Access Control

Nodeaccess and menuaccess modules

• Restrict access to node types and menus for specific user

roles.

• For example, to provide an extranet:

– Only users of role „partners“ can

see the „Extranet“ menu entry

and access nodes of type

„ExtranetPage“.

Page 62: An Introduction to Drupal

Grown Up Drupal - Extending

Really, Drupal is a framework.

Writing modules and using Drupal as database, user management and permission layer is often easier than writing a web app using another framework, even if the app is not a classic example for a CMS.

Need a custom module?

• Write your own.

• Elance, Freelancer.com.

• Publish a bounty on Drupal.org.

Page 63: An Introduction to Drupal

Thank You

Contact:

[email protected]

www.senzalimiti.com