Drupal Wiki

From Stadm
Jump to navigationJump to search


Trying to achieve a MediaWiki like interface on Drupal is a little tricky and messy. It looks like there might be some extra steps necessary to achieve steps like adding Categories, linking items, formatting etc. This page will record these issues and Zack will attempt to address each.

Location

This is currently being tested on the IT drupal installation located at: http://it.eri.ucsb.edu/

  • The wiki can be accessed in one of two ways:
  1. going directly to http://it.eri.ucsb.edu/wiki/
  2. going to the IT eri website listed above, and clicking "Wiki Home" under the "Wiki" side menu.

Structure/Advanced

Modules

To achieve similar effects to MediaWiki, the Drupal "Wiki" uses the Wikitools and Freelinker modules.

  • Zack is currently looking at additional modules that can be added to add more wiki-like functionality, specifically:
  1. Automatically generating table of contents at the top of each page based on syntax
  2. Formatting the MediaWiki syntax

Taxonomy and Categories

Drupal in some ways makes categorizing pages a little easier. Pages are categorized using the terms under the Taxonomy "Categories."

  • Currently, the only two categories are "Documentation" and "Projects"
  • Categories can be added as links to the "Wiki" sidebar menu, but will automatically appear on the wiki/Categories page (This is the basic Taxonomy view that displays links to all registered terms).
    • List of all Pages tagged with term automatically appear on term page (located at wiki/Categories/(term name)
  • "List All Pages" in sidebar is a link to a Page view that contains a table of links to all pages
    • Filtered by Content Type = "Wiki Page"

Default Page Creation Location

  • This can be configured at "admin/config/search/path/patterns" under "Content Paths" -> "Pattern for all Wiki Page paths"

Blocking Anonymous Users

To block anonymous users, the "block_wiki" context is used.

  • If role is Anonymous, and path = wiki or wiki/*
  • Hide content
  • Results in a green alert message at the top of page "Active context: block_wiki" if conditions are met.
    • Still shows page title

Using Wiki

  • To view a page:
  1. Click "List All Pages" under "Wiki" menu in sidebar and locate the page you are looking for on the table or,
  2. Go to wiki/(page name)
  • To add a page:
  1. Type wiki/"your page name here" after the IT ERI URL
  2. Edit the "Body" textarea as you like
  3. If applicable, select checkbox for Category
  4. Your page URL will automatically become "wiki/(page title)"
    1. If you would like to put your page at a different location, you can edit the location by clicking URL Path Settings
    2. Uncheck the box next to "Generate automatic URL alias"
    3. Type desired location at textfield next to "URL alias"

Bugs/Problems

  • Every time a page is added to the wiki, an error message saying "Warning: strpos(): Empty delimiter in wikitools_node_validate() (line 385 of /var/www/vhosts/it.eri.ucsb.edu/sites/all/modules/wikitools/wikitools.module)."
    • Likely a bug in wikitools because it is still in beta for Drupal 7.x