This page aims to discuss the steps necessary to integrate all or parts of DokuWiki into other existing web applications.
Fit is a Framework for Integration Tests and is very useful for acceptance tests (at least within the development work my team performs). There's a WikiEngine for Fit, called FitNesse, which is used to document Acceptance Tests for Java, C# and Oracle (using dbFit). My team already uses DokuWiki as the main source for collaborative documentation and we don't want to “learn” a new WikiMarkupSyntax (specially since all of us prefer DokuWiki's MarkupSyntax). Also, after several plugins have been integrated, our current DokuWiki engine is much more functional and practical than FitNesse (not being a comparison of both, mind you). As such, we aim to integrate Fit (or PHPFIT) in DokuWiki MarkupSyntax.
Has anyone perform any work on this? — José Carlos Monteiro 2007-03-07 13:08
how is possible to make dokuwiki as drupal module? my current web www.mypolaris.com is in dokuwiki. but, i really like all the features come with drupal and plan to migrate to drupal. but, i also like dokuwiki and still want to use it. but… how can i have the best of both? tnx. - DennyHalim
MosheWeitzman: see http://www.foolab.org/node/785 for authentication integration.
does anyone know how to use this scritp? I insert it into inc/auth/drupal.auth.php and then a choose it in conf/local.php but it didn't work. Where do I set the db name, user, pass, url?
http://foolab.org/node/785#comment-16489 for a basic guide.
I'm in the process of fully integrating Dokuwiki into Drupal. I've completed full user-handling integration, namely I've created an auth module for deferring all Dokuwiki user handling to Drupal. I've also updated the Drupal and Dokuwiki Apache Rewrite entries to allow using clean URLs.
Next I want to create a Drupal module for executing Dokuwiki queries in the Drupal application itself. Another problem will be combining the themes of the two applications. I want to do this by creating a minimalistic Dokuwiki theme that strips all headers and footers, recreate Dokuwiki menu items on the Drupal sidebar, and embed Dokuwiki output in a Drupal page.
I have two websites that implement the basic Dokuwiki integration:
A more detailed description of what I did, including all the necessary code, can be found on my Coalface.net site. I'm not much of a PHP developer or particularly versed in Dokuwiki or Drupal, so I'd love any feedback on my work that I can get.
In this brief blog entry I'll explain how to install dokuwiki with drupal authentication. Uses the above auth coding–drupal_ext. So you have Drupal installed and your user account already established. Next install dokuwiki. Once that's done we now append the rewrite prefs for the clean .htaccess style clean-urls. Add to /etc/httpd/conf/httpd.conf (assumes directory = /var/www/html/wiki and Drupal is installed at /var/www/html/*)
We now have a Drupal site, with a prior experience of running PmWiki for 4 years with minimal spamming. When we moved to Drupal, we wanted to retain some of the ease-of-use of wiki, but thought it was a good idea to at least minimally set up authentication. We moved off PmWiki in favour of Dokuwiki, because my experience is that Dokuwiki is cleaner on architecture, and has fewer idiosyncracies than PmWiki.
Since we're monitoring Drupal userid requests manually – we get spamming requests every day – it makes sense for a user to be able to use that Drupal userid and password when he or she wants to edit a Dokuwiki page. Thus, we embarked on the quest for “Drupal integration” of Dokuwiki.
In 2006, we tried the foolab instructions in 2006, and were unsuccessful in making it work. We left Dokuwiki unsecured for some time. We then tried the czarism instructions in 2007, and were still then unsuccessful. (We're not professional programmers, and I even called in a professional this time, but he was also unsuccessful).
I've now found a page mysql_drupal, which is not true integration, just authentication. However, since the first version was written by Andi, we had more confidence that this solution would work. In less than an hour, our programmer had the login using the same userid and password as in Drupal.
There may be a difference in intent, though. For the questions on how to “make dokuwiki as a drupal module” … or “full user-handling authentication” … I believe the desired behaviour is to have a user login to Drupal, which then automatically logs him or her into Dokuwiki. This isn't what we have working, now. The “Login” button still appears, and the user follows the typical userid and password procedure, but Dokuwiki checks against the Drupal's MySQL database of userid and password.
This means that the Dokuwiki editors/authors will have to explicitly log in – the readers can just view the content as a normal web page – but at least users only have to remember one userid and password, i.e. the one in Drupal! {David Ing, 2007/11/27}
any CMS that utilize dokuwiki? so that we can easily move our dokuwiki into more complete CMS but still have our dokuwiki content retain? tnx. - DennyHalim
Yes, Joomla has a nice integration of DokuWiki. It is called JD-Wiki. You can find it here http://www.joomladeveloping.org/component/option,com_jd-wiki/Itemid,28/
There is a Xoops module that neatly embeds Dokuwiki into the Xoops framework.
Perhaps the most realistic approach here would be to go with Kupu. As you can see from the demo, what's being edited is WYSIWYG. Kupu is also well designed for integration with the server side, providing some fairly clear points of access.
One wiki that's done this is twiki as described here. They use an HTML to Twiki parser which transforms what Kupu sends when you click “save”.
Downside is what's being edited is not “raw” wiki text.
Another option might be Wikiwig
Hi, I just came by looking for WYSIWYG for dokuwiki. Went to check out Wikiwig. Note that Wikiwig's home page doesn't seem to handle firefox's View/Text Size/Increase very well. Not sure if that implies anything about the HTML it produces, but you may want to check on that before committing to using it.
You can discuss WYSIWYG here
I've modified the parser.php script for use in phpBB. Here are the steps necessary to use DokuWiki syntax in phpBB:
1. Create a new file in path.to.your.forum/includes/ named wikiparser.php with this content. It's essentially the parser script from DokuWiki but without any reference to a file from the DokuWiki installation so that it can be used standalone. For this reason I had to drop support for interwiki links, acronyms, code syntax formating, custom text replacements and smileys (but phpBB has its own smiley engine). I also dropped support for auto-TOC, since that doesn't make sense in a forums post.
2. Edit the path to your wiki in the head of wikiparser.php. This is necessary for wiki links to work.
3. Modify includes/bbcode.php. Search the following string…
define("BBCODE_UID_LEN", 10);
… and insert after that these two lines:
$phpbb_root_path = './'; include($phpbb_root_path . 'includes/wikiparser.'.$phpEx);
Then search for…
$text = substr($text, 1);
… and insert therafter:
// Use the DokuWiki-Parser $text = parse($text);
Do this twice since there are two ocurrences of the string.
4. Replace the whole content of path.to.your.forum/templates/subSilver/bbcode.tpl with this text. This is needed to avoid conflics between BBCode and the wiki syntax. After that, you should be able to use both BBcode and wiki syntax in your posts.
5. As a final steps you need to adjust the stylesheet of your forum. For example add link classes acording to the DokuWiki stylesheet to be able to distinguish link to existing wiki pages from those to non-existing.
See a working example in this forum.
Notes: I made some modifications to syntax interpreting. If you don't like these, include the simpleformat function from the original DokuWiki parser.
I am not a programmer and this is my first major code modification in PHP. It seems to work for me – which was my primary goal. If you have suggestions how to improve the code, contact me. — Esther Brunner 2005-03-23 12:31
Esther, I've seen your modifications to the syntax in your site (the ins tag, the del tag and the double-exclamation-mark tag) and I'd like to see that included in DokuWiki's oficial syntax. Either you or I should add a Feature Request in FlySpray so Andy and others can comment and work on that as well.
But the main reason for my comment here is to find out if all that you did was just tweaking the parser.php or if you also did an effort to integrate the DokuWiki's own GUI Editor. I've been working (slowly) on integrating a practical WikiMarkup GUI Editor into open-source content-management-systems, such as Drupal, WordPress and osCommerce but so far for me the fastest and easiest way is to integrate TinyMCE or FCKEditor or SPAW. All these WYSIWYG TextArea Editors are good but they lack features I'm seeking:
* Package size, uncompressed, must be as small as possible and not take 2MB of storage space as these 3 do.
— straider 2005-03-23 14:13
or if you also did an effort to integrate the DokuWiki's own GUI Editor
I'm working on that, but have nothing to show yet. I've read about DokuWiki's GUI Editor ported to Drupal, named "Textbar", so after all it must be possible. My Goal is to set up a Blog-Wiki-Forum Environment which all use the same text markup syntax – and I like DokuWiki's best. — Esther Brunner 2005-03-23 15:51
Describe the steps necessary to keep content revisions, with author and summary of changes.
For Dokuwiki administrators some command line tools could be really useful, mainly where there's versions involved. Probably a job for Perl. Some possible results;
Add links to examples of web applications with DokuWiki's integration.
What are the benefits of using WikiSyntax?
What other benefits arise from using DokuWikiSyntax?