SynapseIndia Drupal- Presentation on Drupal Intro

Embed Size (px)

Citation preview

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    1/49

    Drupal Intro

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    2/49

    What is Drupal?

    Open Source software written in php.

    A CMS or content-management system.

    A sophisticated web application building tool.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    3/49

    What is a CMS?

    Simply put, a CMS is a website you build using

    the website itself.

    A content management system(CMS) such as a document

    management system(DMS) is a computer application used to

    manage work flowneeded to collaboratively create, edit,

    review, index, search, publish and archive various kinds of

    digital media and electronic text.[1]

    http://en.wikipedia.org/wiki/Document_management_systemhttp://en.wikipedia.org/wiki/Document_management_systemhttp://en.wikipedia.org/wiki/Work_flowhttp://en.wikipedia.org/wiki/Content_(media_and_publishing)http://en.wikipedia.org/wiki/Content_management_systemhttp://en.wikipedia.org/wiki/Content_management_systemhttp://en.wikipedia.org/wiki/Content_management_systemhttp://en.wikipedia.org/wiki/Content_(media_and_publishing)http://en.wikipedia.org/wiki/Work_flowhttp://en.wikipedia.org/wiki/Document_management_systemhttp://en.wikipedia.org/wiki/Document_management_system
  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    4/49

    What can Drupal be?

    blog

    Forum

    Online newspaper, Portal / Directory

    Brocure site, portfolio, flickr like photo drop

    Social community site, job post board Video site like youtube

    Project management site

    CRM, ERP, SCM, Wiki

    Shopping cart system

    E-learning, training site Dating site

    Anything you can think of

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    5/49

    Why use a CMS?

    It helps manage complexity.

    It provides a user interface (UI) for adding,editing and publishing content.

    It provides a means for collaboration amongmany to perform the above tasks.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    6/49

    Why use Drupal over Wordpress?

    Wordpress was designed only to be a blog with some easy add-ons.

    Drupal was designed to be more of a generalist: its for making anything and is farmore robust.

    Wordpress could be the better choice for blogs since it is better at being a blog than

    Drupal. This is something of debate.

    Wordpress is still a sound choice of CMS for SEO and security; so if wordpress satisfies asimpler projects requirements then by all means use it- it is easier and faster to set upthan Drupal.

    Wordpress is not designed to be highly scalable to many simultaneous users, nor does it

    have flexible roles, permissions, extensible content types, nor does it have plentifulwell-tested, quality add-ons. It has a few and a lot of really poor plugins.

    Caveat: Trying to force Wordpress to do something it cannot do easily with very popularplug-ins can be worse than suffering the learning curve of Drupal.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    7/49

    Why use Drupal over Joomla? (or other CMS)

    It has superior session handling for a CMS.

    It has superior security.

    It is a more consistent, reliable and flexible framework for development.

    It is considered better for SEO from our research.

    It uses a separation of concerns architecture to cleanly and consistently separatestructure, function, form, and presentation in layers (ie: php from data as db/xml,layout and presentation as html and css).

    It heavily uses defaults overrides in code in the form of hooksand in themes inthe form of templates. This makes it extremely flexible.

    Other CMSes do a very verybad job of at least one of the above.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    8/49

    Downsides to the Druup

    Drupal has a steeper learning curve thanwordpress or Joomla.

    Drupal and its developers make no excuse forthis fact- it is a robust, flexible tool

    That said, the drupal community is constantlyaddressing usability and user-experience issuesbecause they want the industry market share.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    9/49

    What is a UI?

    UI is a user-interface, which is a general term

    for the layout of options, widgets and settings

    used to configure the system or manage

    content.

    Site-building activities refer to configuring

    settings or managing content through the UI,

    such as building navigation menus.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    10/49

    Drupal Structure

    Drupal is a database-driven (dynamic)

    application. It requires a database.

    Drupal has a core filesystem whose

    functionality can be extended using the UI

    itself, modules and themes.

    The UI settings are stored in the database.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    11/49

    Modules

    Packages of files in a directory that you uploadinto drupals module space (/sites/all/modules)

    Add functionality to drupal

    Core Modules come shipped with drupal

    Contributed Modules are downloads fromdrupal.org

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    12/49

    Themes

    Packages of files in a directory that you upload

    into drupals theme space (/sites/all/themes)

    Themes adjust the site layout and style. Like

    skinning your media player.

    Themes can be easily changed in the UI.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    13/49

    Drupal Database

    Drupals database tracks things like :

    Site and Module settings,

    Users information, Access information,

    Logging information,

    Permissions and User Roles,

    System Paths

    Content and content metadata

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    14/49

    Nodes

    A node is the primary form of content in adrupal site. At a minimum it is a title and abody, and can be specialized.

    A page and story for example are nodetypes that have a specific node settings.

    A node type is a blueprint for creatinginstances of content of a particular type.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    15/49

    Nodes (cont)

    Not everything in Drupal is a node.

    This is important!!

    Ex: A user is not a node. A taxonomy is not anode. An account is not a node.

    Knowing this is important for evaluation of

    what can and cannot be easily done throughthe UI, without additional programming.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    16/49

    Layout and Regions

    A Region is an area in a layout, such as a header, footer,content, left/right sidebar into which blocks can beplaced and arranged.

    A block is a box containing some information

    A node resides only in the content area of the layout(except in special circumstances).

    Think of the content region as a big node block thatallows other blocks in it but the node itself cant move.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    17/49

    Blocks

    Blocks are added by modules.

    Blocks can contain views, widgets, menus,

    nodes (in special circumstances), and panels.

    Blocks can be moved around through the UI

    Blocks can be styled individually.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    18/49

    Additional Terminology

    Viewsan interface for making customizedlists of the data contained in the drupaldatabase.

    Panelsan interface for making customizedlayouts of nodes available to the panelsmodule.

    Widgetsa general term for interactive formelements or graphs that are enabled bymodules.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    19/49

    Admin Menu

    The administrative menu is a part of the UI

    that allows one to configure Drupals settings.

    The settings available depend on which

    modules are installed and enabled.

    Permissions allow users to have

    administrative access to module settings.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    20/49

    Users

    All CMSes (wordpress, Joomla, Drupal) have a

    user login system; users have a username/pw.

    Drupal also supports the concepts of 1) Roles

    and 2) Permissions.

    Roles are user designations to groups having

    the same set of permissions.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    21/49

    Anonymous User

    A (not-logged-in) site visitor is called a guest,

    visitor or anonymous user.

    Has a user-id (uid) of 0 (zero).

    All anonymous users belong to theanonymous user role (a role ID of 1) and have

    a set of permissions assigned to them.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    22/49

    Authenticated User

    A user in drupal may belong to one or moreroles.

    Every registered user in Drupal belongs to atleast the authenticated user role.

    Authenticated user role has a role ID of 2

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    23/49

    Root Admin User

    The root user or root admin has the ability

    to do anything on the site and is a special user.

    The root user has a user-id (uid) of 1.

    The root user does NOT have role-permissions to set because they are effectively

    gods within Drupal.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    24/49

    Managing Permissions

    KEY concept: if you grant permission to an

    authenticated user, it applies to ALL roles

    except the anonymous user.

    To grant a permission to everyone on a site,

    you must grant the permission to both the

    anonymous user and authenticated user.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    25/49

    Managing Permissions

    To grant permission to only a newly created

    dentist role, tick the permission on that role.

    Leave all the other roles deselected.

    If you grant to both the dentist role AND theauthenticated user role, you would be doing

    it wrong. Drupal assumes you know this.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    26/49

    Recipe: Change Site Information

    In Administer > Site Configuration > Site

    Information:

    Change the information to suit your site

    following the help text.

    Dont change the Default front page just yet.

    Click Save configuration

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    27/49

    Recipe: Change Date and Time

    In Administer > Site Configuration > Date and

    Time:

    Change the timezone to the correct time for

    America/Denver (-0600 UTC)

    Change the time formats

    Click Save Configuration

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    28/49

    Recipe: Clean Urls

    Clean URLs remove the ?q= from the location

    bar in your web browser.

    In Administer > Site Configuration > Clean

    Urls:

    Tick Enabled

    Click Save Configuration

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    29/49

    Clean Urls Issue

    If Clean URLs is an unchangeable option,then there is a misconfiguration of the drupalsite hosting environment.

    Contact your local IT support for assistance orconsult the drupal handbook for more info.

    For the purposes of this demo, its notimportant but it -is- important to enable later.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    30/49

    Recipe: Add a user

    Go to Administer > User Management > Users

    Click Add user

    Choose options. Click Create New Account

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    31/49

    Recipe: Add a user

    A user can also add themselves by registering, ifthe root user has allowed this option.

    Go to Administer > User Management > UserSettings

    Tick Visitors can create accounts and no

    administrator approval is required

    Click Save Configuration

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    32/49

    Recipe: Add Roles

    You will note that anonymous and

    authenticated users are there by default,

    undeletable.

    Type in the box below the roles in the Name

    column. Click add role. Thats it.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    33/49

    Recipe: Edit / Delete role

    Click edit next to the role name.

    Here you can change the name or delete the

    role.

    Warning: If you click delete role, there is NO

    confirmation. This can be bad.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    34/49

    Recipe: Assign multiple roles to User

    In Administer > User Management > Users:

    Click the edit link under operations for a user Under Roles, Tick an additional role you

    created.

    You will notice authenticated user is locked. Scroll to the bottom and click Save

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    35/49

    Recipe: Altering Permissions

    Under Administer > User Management > Permissions: you will seethere is a permissions column and role columns.

    Scroll down to the user module section.

    Tick change own username in the authenticated user column.

    Tick Save Permissions

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    36/49

    Recipe: Build Menu

    Under Administer > Site Building > Menus:

    Click Primary Links

    On the Primary Links List Items page, click Add Item

    In Path, type contact. In Menu link title, type Contact Form.

    Change weight to 50 (drupal 6.x; 10 in drupal 5.x)

    Click Save.

    You will notice that Contact Form appears now on the far right of yourprimary links. Click it to go to the contact form.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    37/49

    Recipe: Create About Page

    In the Navigation (left sidebar), click Create Content

    Click Page under the content type listing.

    In the Title, type About Us. In the body type This is my first drupal page.

    Expand the Menu settings fieldset.

    In the Menu link title type About Us.

    Change the weight to 49.

    Expand the URL path fieldset and type about-us

    Click Save

    You should now see the About Us menu item in the Primary Link navigation. Click it to go to thisnewly created node.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    38/49

    Recipe: Get modules

    Default Drupal installs can only do so much.

    Go to http://drupalmodules.comto find a module that

    supports what you are trying to do.

    Do rely on the ratings here as they are tied to download /

    popularity metrics from http://drupal.org

    http://drupalmodules.com/http://drupal.org/http://drupal.org/http://drupalmodules.com/
  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    39/49

    Recipe : Change Site (Admin) Email

    Note: There are multiple places to change the email address for asite root user administrator. You may have to dig around forthem in admin menu when logged in as the root user. Get logininfo from Salesforce.

    In site information : admin/settings/site-information

    Site-wide contact form settings : admin/build/contact (editoperation)

    Mass contact settings (if used) : admin/build/mass_contact/settings

    Mail settings (different places, ex uses mimemail) :admin/settings/mimemail

    User register notify : admin/settings/register_notify

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    40/49

    Recipe: Halp! The site is messed up

    If the login disappears and you cant login, go to

    www.yourdomain.com/user or

    www.yourdomain.com/index.php?q=user

    If clean URLs is not working, substitute the first forward slash

    (/) after the domain/host with /index.php?q= without the

    quotes.

    If all else fails, call Chris or Alex to build a GUI interface in

    Visual Basic to track down the perpetrator inrealtime.

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    41/49

    Installing Modules

    Download (from drupal.or) and Unpack module tarballs(*.tar.gz) files to the folder inside.

    Upload the module folder to

    /sites/all/modules.

    Create the modules and themes directories if they arenot there.

    Go to Administer > Site Building > Modules : and tickEnabled next to the module to enable it and click SaveConfiguration

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    42/49

    Using Modules

    A newly enabled module will add anadministration menu.

    Go to that module and read the help beforechanging anything.

    Play around and learn its feature set.

    Install the Advanced Help module to get moreverbose help with modules.

    Modules Used on Almost every Drupal Site

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    43/49

    Modules Used on Almost every Drupal Site

    Most Useful Contributed Modules

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    44/49

    Most Useful Contributed Modules

    Administrationmenu

    CCK Views String Overrides Backup andMigrate

    SEO Checklist SEO ComplianceChecker

    Pathauto Path Redirect Global Redirect

    Search404 Meta Tags Global GEOurl Html Purifier Page Title

    Menu Attributes New XML Sitemap Site Map Taxonomy Manager Token

    Auto Assign Role(+patch)

    Ubercart Date Mollum / Spam Captcha

    WYSIWYG API FCKEditor IMCE Chaos Tools +Delegator

    Panels

    Actions Triggers Notify Scheduler

    Addthis / Diggthis/Sharethis

    Guestbook Simplenews GoogAnalytics

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    45/49

    Most Useful Contributed Modules (OLD)

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    46/49

    Most Useful Contributed Modules (OLD)

    Administrationmenu

    CCK Views String Overrides Backup and Migrate

    SEO Checklist SEO Compliance

    Checker

    Pathauto Path Redirect Global Redirect

    Search404 Meta Tags Global GEOurl Html Purifier Page Title

    Menu Attributes New XML Sitemap Site Map Taxonomy Manager Token

    Auto Assign Role

    (+patch)

    Ubercart Mollum / Spam Captcha

    WYSIWYG API FCKEditor IMCE

    Actions Triggers Notify Scheduler

    Date Chaos Tools +

    Delegator

    Panels

    Addthis / Diggthis/Sharethis

    Guestbook Simplenews GoogAnalytics

    Advanced: Advanced: ApacheSolr Search (wecannot support yet)

    Advanced: OpenCalaisRDF metadataWS

    Advanced: Devel(danger)

    Advanced: PHPmailer/SMTP Auth

    i b i d

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    47/49

    A warning about using Free and Low

    Cost (downloaded) Themes

    They are more difficult to customize than starting from scratch, but faster to use.

    Some of the markup is not seo-friendly.

    Some of the markup is over-engineered and messy; less is more.

    Free or amateur / low-cost themes can be confusing if you look at the code; this mayimpair your ability to learn drupal theming.

    Some of the markup may be in tables or liquid layout and this may be hard to changefor your particular project, even if it looks nice to you.

    Best practice suggests you either find a theme design and mimic its look-and-feel or dothe traditional photoshop mock up.

    If you take someone elses theme, you dont know what youre going to get and this canhinder your ability to develop

  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    48/49

    Getting free themes

    http://themegarden.org/drupal6/

    http://drupal.org/project/Themes

    http://themebot.com/free-website-templates/drupal-themes

    Google drupal themes youll find a bunch of

    stuff. Buyer beware.

    http://drupal.org/project/Themeshttp://themebot.com/free-website-templates/drupal-themeshttp://themebot.com/free-website-templates/drupal-themeshttp://themebot.com/free-website-templates/drupal-themeshttp://themebot.com/free-website-templates/drupal-themeshttp://themebot.com/free-website-templates/drupal-themeshttp://themebot.com/free-website-templates/drupal-themeshttp://themebot.com/free-website-templates/drupal-themeshttp://themebot.com/free-website-templates/drupal-themeshttp://themebot.com/free-website-templates/drupal-themeshttp://drupal.org/project/Themeshttp://drupal.org/project/Themes
  • 8/10/2019 SynapseIndia Drupal- Presentation on Drupal Intro

    49/49

    Most Useful Themes

    Zen(use starter kit to subtheme)

    960 grid based themes Garland(use as admin theme)

    Blarland an evil copy ofgarland. Place it insites/all/themes andchange the name of garlandto blarland in folder, andfile names esp in the infofile.