Difference between revisions of "Electowidget Installation"

From Electowiki
Jump to: navigation, search
(Install instructions)
(No difference)

Revision as of 18:30, 29 October 2005

Below are step-by-step instructions for installing Electowidget at your MediaWiki installation on a UNIX machine running the Bash shell (typical configuration for many Linux hosting providers):

  1. Download Electowidget
  2. Set the MWLOC variable
  3. $ export MWLOC=/path/to/mediawiki

    Note: Please substitute the location in your local installation for the /path/to/mediawiki portion.

  4. Unpack Electowidget into your extensions directory
  5. $ cd $MWLOC/extensions
    $ tar zxvf /path/to/electowidget-0.1.0.tar.gz
  6. Move or symlink it
    • Approach #1 (moving):
    $ mv Electowidget-0.1.0 Electowidget
    • Approach #2 (symlink):
    $ ln -s Electowidget-0.1.0 Electowidget
  7. In order for Electowidget to work with MediaWiki, there is a slight modification that is needed to MediaWiki. Apply the provided patch to your MediaWiki install.
  8. $ cd $MWLOC
    $ patch -p0 < /path/to/mediawiki/extensions/Electowidget/MediaWiki/mediawiki-1.5.1.patch
  9. Edit LocalSettings.php using your preferred text editor
  10. $ $EDITOR LocalSettings.php
  11. Add the following text near/at the end of LocalSettings.php
  12. define('ELECTOWIDGET_MAIN_NS', 100);
    define('ELECTOWIDGET_TALK_NS', 101);
    define('ELECTOWIDGET_SUBDIR', 'extensions/Electowidget/');

    Note: 100 and 101 are namespace identifiers which may conflict with other namespace identifiers if you've customized your MediaWiki installation. Please choose unique values for these numbers.

  13. Test your installation. Visit a page in the "Election:" namespace, such as "Election:Test". You should get a warning that reads "Empty page. Please edit this page, providing JSON-formatted data about the election you'd like to set up.". If so, congratulations, you've successfully installed Electowidget.