Title: Top 5 Non-Obvious Drupal Modules
1Top 5 Non-Obvious Drupal Modules
Presented byRuss Bomhof Geoff
HingChicagoland Library Drupal Group December
7, 2009
2Top 5 Non-Obvious Drupal Modules
About CRL
- Consortium of 250 North American Universities
and Colleges - Primary Resources for faculty and students
- Cooperative Acquisition and preservation of
international resources for research and teaching
3CRL Then and Now
Drupal 6!
VBScript ASP / MS Access DB Static HTML w/
Dreamweaver Templates
4Things We Learned
Too often, web site owners allow their
maintenance methods and their personnel skills to
drive decisions about how the web site works.
That's completely backwards. You should first
figure out how you want your web site to work,
then employ solutions/people/skills to make that
happen.
- Scott Crevier on the uwebd mailing list
5Things We Learned
As far as we know, there is no module that will
force a team to communicate and collaborate.
6Things We Learned
Theres more than one way
Photo by Karamellzucker via Flickr
7Top 5 Non-Obvious Drupal Modules
Obvious
- Views
- Content Construction Kit (CCK)
- Panels
- Node Import
- Workflow
- Drush
- Google Analytics
8Top 5 Non-Obvious Drupal Modules
Non-Obvious
- Nodequeue
- Module Grants
- Menu Block Split
- Views Accordion
- Pathauto Custom Token
9So what news items did you want on the front page?
We need to have the 3 most recent news
and events, but not the one about the meeting.
Oh, and that event is too old. Oh, make sure to
add ...
Ummmm. Right. Just send me that list in e-mail.
10Top 5 Non-Obvious Drupal Modules
1. Nodequeuehttp//drupal.org/project/nodequeue
11If you could get this done
By the way, I need you to build this huge new
section of the site from a bunch of incoherently
named Word documents, e-mails, and spreadsheets.
Ok. When does this need tobe done?
by the end of the day, that would be great.
Oh, and it will need to be approved before it
gets published.
12Rapid content development
vs.
Review and collaboration
13Top 5 Non-Obvious Drupal Modules
2. Module Grantshttp//drupal.org/project/module_
grants
14Or, use Deploy
From the amazing demo of the Deploy module,
http//www.youtube.com/watch?v7PjwT0HWHxw
15Category, Menu HTML, Menuwriter,
Menu Firstchild, Multiple Node Menu, ...
What module should I use for menus?
Well, theres Menu Block, or Nice Menus. Submenu
Tree,
16Top 5 Non-Obvious Drupal Modules
3. Menu Block Splithttp//drupal.org/project/menu
_block_split
17It should open and close.
We need our Topic Guide links to open and close
like the E-Collections, web specialist.
No problem. What content would you like to use?
18(No Transcript)
19(No Transcript)
20(No Transcript)
21(No Transcript)
22(No Transcript)
23Top 5 Non-Obvious Drupal Modules
4. Views Accordionhttp//drupal.org/project/views
_accordion
24(No Transcript)
25Old and busted http//www-old.crl.edu/content.asp
?l13l255
26Top 5 Non-Obvious Drupal Modules
5. Pathauto Custom Tokenhttp//drupal.org/proje
ct/pathauto
27replacement '' if (node) values
array() // Try to get the menu data. mlid
db_result(db_query("SELECT mlid FROM
menu_links WHERE link_path 's'", 'node/'.
node-gtnid)) // Now get the menu related
information. if (!empty(mlid)
!empty(node-gtmenu'mlid') !empty(node-gtmenu
'plid')) menu_link menu_link_load(mlid)
menus menu_get_menus() menu
isset(menusmenu_link'menu_name') ?
menusmenu_link'menu_name' ''
trail_raw _menu_titles(menu_link,
node-gtnid) trail array() foreach
(trail_raw as title) trail
check_plain(title) values'menupath-r
aw' implode('/', trail_raw)
else values'menupath-raw' ''
values'menu-link-title' ''
values'menu-link-title-raw' ''
replacement values'menupath-raw' // Start
with the default 'menupath-raw' replacement
str_replace('Collaborations/Area Studies',
'Area Studies', replacement) replacement
str_replace('Collaborations/GRN', 'GRN',
replacement) replacement
str_replace('Collaborations/Collaborative
Digitization', 'Collaborative Digitization',
replacement) return replacement
28Alternately, write a custom module
/ Implementation of hook_token_list().
/ function crl_helpers_token_list(type
'all') if (type 'global' type
'all') // We don't implement any global
tokens yet. if (type 'node' type
'all') // Node tokens here
tokens'node''crl-menupath-raw' t('A
customized version of the menupath-raw token
for the CRL menus that puts certain items (e.g.
GRN) at the top level.') return
tokens / Implementation of
hook_token_values(). / function
crl_helpers_token_values(type, object NULL)
// Very similar to code in previous slide //
29Thanks!
Top 5 Non-Obvious Drupal Modules
Russ Bomhof rbomhof_at_crl.edu Geoff Hing
ghing_at_crl.edu www.crl.edu