Your SlideShare is downloading. ×
5 Important Tools for Drupal Development
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Introducing the official SlideShare app

Stunning, full-screen experience for iPhone and Android

Text the download link to your phone

Standard text messaging rates apply

5 Important Tools for Drupal Development

14,502
views

Published on

Published in: Education, Technology, Design

0 Comments
12 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
14,502
On Slideshare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
162
Comments
0
Likes
12
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide
  • modules
  • Is familiar; it looks and acts like api.drupal.org
  • -Includes reference to contrib modules: Functions & methods, Source code -Includes many modules for D5, D6, D7, & D8
  • -User permissions control what user roles can use it -Admins intended role
  • -Hunting for the correct links and 4 page loads in the first example -A faster approach in the second -Allows you to get around a lot faster as an admin and perform everyday tasks
  • Small amount of shell experience Willingness to learn
  • -Information available online and inside README.txt in drush module -As well as many example use cases
  • -Can do this for many different drupal sites -Advanced setups can have different site aliases and site profiles to load different configurations for each specific Drupal install
  • -tip of the iceberg here -ways to quickly install brand new sites in 1 line of code that takes seconds -easily sync development sites to production sites
  • -Firebug for Drupal themeing. -Due to erratic behavior do not enable only for developing. -Turn on and off with drush makes it quick and easy!
  • -Drupal theme is built from many theming functions and templates we can call theming hooks. -Can be confusing to know what function in source is responsible for theme -this is where http://drupal.org/node/173880
  • -Drupal theme is built from many theming functions and templates we can call theming hooks. -Can be confusing to know what function in source is responsible for theme -this is where
  • -click on the link to template source for easy “Copy + Paste” as a base for new template -use candidate template files as naming reference for saving in theme directory -
  • -click on the link to template source for easy “Copy + Paste” as a base for new template -use candidate template files as naming reference for saving in theme directory -
  • Transcript

    • 1. 5 Important Tools for Drupal Development July 14, 2011
    • 2. 5 Important Tools for Drupal Development
      • Overview
      • A talk of 5 tools to aid you in developing, administering, and maintaining Drupal sites.
      • Goals
      • Spark an “ ah hah! ” moment
      • Introduce new ideas and techniques
      • Get you excited about Drupal
      ANTHOLOGYMARKETING.COM
    • 3. DRUPALCONTRIB.ORG
      • TOOL #1
      ANTHOLOGYMARKETING.COM
    • 4. Contrib is
      • how Drupal is extended and customized.
      • made up of 8292 modules today.
      • written by the community and shared under the same GNU Public License (GPL) as Drupal.
      • not shipped with Drupal core releases.
      • shaping future releases of Drupal.
      ANTHOLOGYMARKETING.COM
    • 5. drupalcontrib.org
      • Search contrib modules
      ANTHOLOGYMARKETING.COM
    • 6. Contrib API reference ANTHOLOGYMARKETING.COM
    • 7. Add modules to documentation ANTHOLOGYMARKETING.COM
    • 8. ADMINISTRATION MENU
      • TOOL #2
      ANTHOLOGYMARKETING.COM
    • 9. A simple administrative interface
      • The menu is theme independent
      • CSS-based drop down style menu
      • Eliminates unnecessary page loads and clicks
      • For D6, D7
      ANTHOLOGYMARKETING.COM
    • 10. A comparison
      • Create a new CCK field for a custom content type
      • Workflow #1 – without administration menu
      • Workflow #2 – with administration menu
      ANTHOLOGYMARKETING.COM
    • 11. Workflow example #1
      • Click on Administer
      ANTHOLOGYMARKETING.COM
    • 12. Workflow example #1
      • Click Content Types
      ANTHOLOGYMARKETING.COM
    • 13. Workflow example #1
      • Click manage fields
      ANTHOLOGYMARKETING.COM
    • 14. Workflow example #1
      • Find desired field row and click on configure
      ANTHOLOGYMARKETING.COM
    • 15. Workflow example #2
      • Navigate the admin menu until you find the desired field and click on configure
      ANTHOLOGYMARKETING.COM
    • 16. DRUSH
      • TOOL #3
      ANTHOLOGYMARKETING.COM
    • 17. What is drush?
      • Dru pal + sh ell = Drush
      • Drush is a command line shell and scripting interface for installing, developing, and maintaining Drupal sites.
      • Intended Users
        • Developers
        • Admins
      ANTHOLOGYMARKETING.COM
    • 18. Requirements
      • Server
      • CLI-mode capable PHP binary, PHP 5.2 or greater
      • Drupal 5.x-2.5 or later
      • SSH access
      ANTHOLOGYMARKETING.COM
    • 19. Installation
      • Download (and extract):
      • ~ $ wget http://ftp.drupal.org/files/projects/drush-7.x-4.4.tar.gz
      ANTHOLOGYMARKETING.COM Make sure drush is executable: ~ $ chmod u+x /path/to/drush/drush Add Alias to ~/.bashrc: ~ $ alias drush= ‘ /path/to/drush/drush ’ Reload bash and type drush: ~ $ drush
    • 20. Using Drush
      • Navigate to Drupal site folder:
      • ~ $ cd /path/to/drupal/web
      ANTHOLOGYMARKETING.COM Check site status: ~ $ drush status Drupal version : 6.22 Site URI : http://default Database driver : mysqli Database hostname : localhost Database username : drupaluser Database : Connected Drupal bootstrap : Successful etc…
    • 21. Example use cases
      • Download (and extract) views module:
      • ~ $ drush dl views
      ANTHOLOGYMARKETING.COM Clear site cache: ~ $ drush cc Run cron: ~ $ drush cron Update core, enabled modules, and database: ~ $ drush up
    • 22. DEVEL THEMER
      • TOOL #4
      ANTHOLOGYMARKETING.COM
    • 23. Devel Themer
      • Theming tool
      • Depends on Devel
      • No current stable release due to erratic behaviors in less stable browsers
      • Turn on/off with drush
      • For D6, D7
      ANTHOLOGYMARKETING.COM
    • 24. Drupal Theme ANTHOLOGYMARKETING.COM http://drupal.org/node/173880
    • 25. Drupal Theme ANTHOLOGYMARKETING.COM http://drupal.org/node/173880
    • 26. Devel Themer in action
      • Theme hierarchy
      • Template information
      • Link to template source file
      • Possible names of overriding template files
      ANTHOLOGYMARKETING.COM
    • 27. Remember
      • Enable/Disable devel_themer with drush
      • After enabling, refresh your browser to load the themer
      • Check box turns themer on
      • Hover over elements on the page
      • Use suggested overrides and naming conventions
      • Clear cache and test theme
      ANTHOLOGYMARKETING.COM
    • 28. DRUPAL FOR FIREBUG
      • TOOL #5
      ANTHOLOGYMARKETING.COM
    • 29. Drupal for Firebug
      • Extends the Firefox browser plugin, Firebug
        • http://getfirebug.com/
      • Enhancing Drupal debugging through the browser console.
      • Provides insight into node, form, user objects
      • Works with Devel module to display SQL queries and execute PHP from the browser
      • Also works with Views if installed
      ANTHOLOGYMARKETING.COM
    • 30. Installing Drupal for Firebug
      • Install Firebug
        • http://getfirebug.com/
      • Install Drupal for Firebug Add-on:
        • https://addons.mozilla.org/en-US/firefox/addon/drupal-for-firebug/
      • Install Drupal for Firebug module:
        • http://drupal.org/project/drupalforfirebug
      ANTHOLOGYMARKETING.COM
    • 31. Viewing objects
      • Visualize the processing of objects
        • First the node is loaded
        • Then ready to be viewed
        • Then altered by modules
      ANTHOLOGYMARKETING.COM
    • 32. Helping developers
      • Developers can write to firebug log!
      • Example use in custom module:
      ANTHOLOGYMARKETING.COM function firep($element, $title = NULL) http://jbenner.net/blog/drupal-for-firebug
    • 33. Now available for Chrome!
      • Use your preferred developing browser!
      ANTHOLOGYMARKETING.COM
    • 34. Resources
      • Drupal API Reference
      • Drupal core: http://api.drupal.org
      • Drupal contrib: http://drupalcontrib.org
      • Administration Menu
      • Project page: http://drupal.org/project/admin_menu
      • Demo: http://www.youtube.com/watch?v=3YgnIFi73QI
      ANTHOLOGYMARKETING.COM
    • 35. Resources
      • Drush
      • Project page: http://drupal.org/project/drush
      • Home page: http://drush.ws
      • Installation: http://openspring.net/tip/how-to-install-drush-serverwide-in-less-than-one-minute
      • Devel Themer
      • Project page: http://drupal.org/project/devel_themer
      • Themable output: http://drupal.org/node/173880
      • Template preproccess: http://drupal.org/node/223430
      ANTHOLOGYMARKETING.COM
    • 36. Resources
      • Drupal for Firebug
      • Firebug: http://getfirebug.com/
      • Firefox Add-on: https://addons.mozilla.org/en-US/firefox/addon/drupal-for-firebug/
      • Chrome Add-on: https://chrome.google.com/webstore/detail/imlijcpfmhmifofiihbofoamohkdbblc
      • Project page: http://drupal.org/project/drupalforfirebug
      • Review: http://jbenner.net/blog/drupal-for-firebug
      ANTHOLOGYMARKETING.COM
    • 37. Questions? ANTHOLOGYMARKETING.COM