Revision [15473]

This is an old revision of WikiInAVacuum made by BrianKoontz on 2006-10-09 20:38:08.

 

Wiki In A Vacuum


Purpose


This is an extension of the InvisibleWiki process advocated by DarTar. His motto is "Look ma, no source code changes!" My motto is "Look ma, no one can tell that it's a wiki unless they look really hard!"

Seriously, though: The difference here is one of philosophy. DarTar's goal is to set up a process that creates an "invisible wiki" (a wiki that doesn't look like a wiki to the casual observer) without the need for changes to Wikka's core code. My goal is to set up a process that creates a "wiki in a vacuum" that, to the casual observer, contains a minimum of wiki artifacts.

There will be a couple of hacks here that will require source code changes to do things like get rid of pesky headers and footers, not allow registrations (but do allow logins), and add some new stylesheet elements. This is a work in progress. I can't guarantee this will work on any specific version (I'm using the latest code from trunk), but it should give one a good idea of where code changes need to be made to disable or eliminate the "wikish" elements.

Modifications


  1. I would suggest initially following the procedures in InvisibleWiki. You might find that the result is adequate for what you need, and there is no reason to modify anything else (other than stylesheets). However, you might be interested in the following step.
  1. As an alternative to disabling Wikka default pages through the use of manual ACL changes, copy and paste the following code in a file called disable_default_pages.php in your top-level wiki directory and follow the instructions:
<?php

/*
 * USE THIS ONLY ON A NEWLY-INSTALLED WIKKA SITE!
 * REMOVE THIS FILE AFTER YOU HAVE RUN IT!
 *
 * Instructions:
 *    Set 'rewrite_mode' in wikka.config.php to '0' if set to '1'
 *    Rename .htaccess to .htaccess.save
 *    Copy this content into a file called
 *      "disable_default_pages.php" in your top-level wikka directory
 *    Invoke this file from the browser
 *    Move .htaccess.save to .htaccess
 *    Set 'rewrite_mode' in wikka.config.php to '1' if set
 *      previously
 * REMOVE THIS FILE AFTER YOU HAVE RUN IT!
 */


include('libs/Wakka.class.php');
define('WAKKA_VERSION','trunk');

$configfile = 'wikka.config.php';
if(file_exists($configfile)) include($configfile);
else {
    echo $configfile."does not exist!";
    exit;
}

$wakka =& new Wakka($wakkaConfig);
if (!$wakka->dblink)
{
    echo '<em class="error">'.ERROR_NO_DB_ACCESS.'</em>';
    exit;
}

$default_pages = array();
if($r = $wakka->Query('select tag from wikka_pages')) {
    while($row = mysql_fetch_assoc($r)) $default_pages[] = $row;
    mysql_free_result($r);
}

foreach($default_pages as $pages) {
    foreach($pages as $page) {
        echo "Locking page: ".$page;
        if(preg_match('/HomePage/',$page)) {
            echo "...skipping<br/>";
            continue;
        }
        if(preg_match('/UserSettings/',$page)) {
            echo "...skipping<br/>";
            continue;
        }
        $wakka->Query("insert into wikka_acls (page_tag, read_acl, write_acl, comment_acl) values ('$page', '!*', '!*', '!*')");
        echo "...done<br/>";
    }
}
?>
There are 2 comments on this page. [Show comments]
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki