su2 :: software · texts · graphics · photography · uni · me · links

up

Installation
============

Easy way: Copy the patch calendar-x.y+tavi-a.b.diff (where x,y and a,b are
the version numbers of calendar and Tavi) into your Tavi base directory and
apply it with the command:

patch -p1 < calendar-x.y+tavi-a.b.diff

Warning: This makes changes to your Tavi installation and may not work with
other Tavi versions other than the one specified. It may also partially fail
if you already made changes to the sources. Make a backup before (just in
case) or do the few steps manually:

- Copy calendar.php to a directory of your Wiki.
  I made a subdirectory called "macros" (hoping that there will be more macros
  in the future) and placed it there.
- Add the following line to parse/macros.php:
  require_once('path/to/calendar.php');
- Add the following element to the Array $ViewMacroEngine in lib/default.php:
  'Calendar' => 'view_macro_calendar'

Configure the default settings in the calendar.php as you like. See the
"Configuration" section on top of the file.

Now you can use the macro by writing [[Calendar]] anywhere in your wiki page.

The script is tested with Tavi 0.22. Older versions may not work or require
different steps to install.