I News I Features I Downloads I Installation I Documentation I License I Roadmap I

GWiki Features Developer View

Show this page as slide show

GWiki is not only an wiki application, but also an plattform to develop web base applications.

GWiki Features for developer

Introduction to GWiki Features.


Customizing Goals

  • Change Look of Pages
  • Create public web pages with coperate style
  • Change way to do things.

Customize Tools


  • HTML, CSS, Javascript
  • GWiki internals
  • JSP
  • Groovy (Java)

Extending Goals

  • Adapting to runtime environment
  • Organize your Content
  • Provide alternative Access

Extending Tools

  • Create your own Macros
  • Implement services for GWiki infrastrukture.
  • Implement Filter to hook into core processes
  • Create own GWiki Element types.
  • Write dynamic pages.

Blueprint template

Define a form, which filled by the user.
A Blueprint template is a wiki page located in admin/blueprints.

Fill this form for your template.
Name:  {input:text|name=name|size=40|maxlength=10}.
{input:inputType=label|value=This is only a label and will not be included in resolved blueprint}
This text will not shown in the evaluated wiki.
{input:radio|value=First|name=radio} {input:label|value=First}
{input:checkbox|name=checkboxp|checked=true}{input:label|value=Choose it.}
{input:select|name=selectp|value=Second|values=First, Second, Third}

Blueprint insert

Blueprint result

Extending Sample: Slide shows 1

Defining a new Meta template.

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
    <bean id="config"
        <property name="elementType" value="gwiki" />
        <!--  1 Hour -->
        <property name="elementLifeTime" value="3600000" />
        <!--  no controlerId -->
        <!--  no controlerClass -->
        <property name="parts">
                <entry key="Controler">
                        <property name="pageId" value="inc/s5template" />
                        <property name="parts">
                                <entry key="MainPage">
                                        class="de.micromata.genome.gwiki.page.impl.GWikiWikiPageArtefakt" />

"inc/s5template" defines a new template

Extending Sample: Slide shows 2

The JSP Template

boolean showSlide = "true".equals(wikiContext.getRequestParameter('asSlide'));
if (showSlide) {
    String s5f = wikiContext.localUrl("static/s5");
    String s5h = """
        <meta name=\"version\" content=\"S5 1.1\" />
        <meta name=\"defaultView\" content=\"slideshow\" />
        <meta name=\"controlVis\" content=\"hidden\" />
    <link rel=\"stylesheet\" href=\"${s5f}/slides.css\" type=\"text/css\" media=\"projection\" id=\"slideProj\" />
    <link rel=\"stylesheet\" href=\"${s5f}/outline.css\" type=\"text/css\" media=\"screen\" id=\"outlineStyle\" />
    <link rel=\"stylesheet\" href=\"${s5f}/print.css\" type=\"text/css\" media=\"print\" id=\"slidePrint\" />
    <link rel=\"stylesheet\" href=\"${s5f}/opera.css\" type=\"text/css\" media=\"projection\" id=\"operaFix\" />
    <script src=\"${s5f}/slides.js\" type=\"text/javascript\"></script>
%><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<div class="layout">
<div id="controls"><!-- DO NOT EDIT --></div>
<div id="currentSlide"><!-- DO NOT EDIT --></div>
    wikiContext.setRequestAttribute('GWIKI_SLIDESHOW_SECTION', 'layout');
<div class="presentation">
} else {
%>  <a target="slideshow" href="#" 
    onclick="window.open('<%=wikiContext.localUrl(wikiContext.getCurrentElement().getElementInfo().getId()) %>?asSlide=true', 'gwiki_slideshow', 'resizable, scrollbars'); return false;">As Slide</a><br/>
wikiContext.setRequestAttribute('GWIKI_SLIDESHOW_SECTION', 'slides');

Extending Sample: Slide shows 3

Create some Macros

  • slideshow, slideheader, slidefooter, slide, ...

Extending Sample: Comments

  • Comments specific Macros.
  • Inserted into wiki or in template.
  • ActionBean handling macro command (create, edit, delete)
  • Inserted into host page via Ajax
  • Comments itself wiki elements organized in file system.

Extending More

  • Blog
  • Forum
  • name it.

Using Taglibs inside wiki

Now use the macro:

{cout:value="This will printed via jsp: ${x}"}{cout}

Now use the macro:

This will printed via jsp: Hallo

Using Groovy

for (int i in 1..10) {
 out.println("Hello " + i + "<br/>");

Access to:

  • GWiki infrastructure
  • GWiki Element+Artefakt
  • Web application

All is GWiki

  • All internal pages in GWiki are implemented using GWiki.

  • With sufficient rights you can also edit the edit page.
  • Open the Admin/ Wiki Control and edit it
    • Controler: ActionBean
    • InputForward: JSP
    • MainPage (optional) text parts
    • Settings

Integrate Goals

  • Make usage of GWiki functions in your web applications.
  • Embedd content centric pages in your application
  • Make gui parts editable by business department.
  • => Register GWiki Servlet in your web.xml

Integrate for Internationalization

  • Use Standard Java I18N properties in common Frameworks.
  • Example, JSP: <fmt:message key="my.key"/>

Integrate for GUI parts

  • Dynamic Pages with logic (developers part) and text (business part).
  • HTML. Too complex for I18N.
  • => Just include page or fragment of page
  • If current user has edit rights, directly can edit fragment.

Wicket Support

  • Using gwiki internationalization.
  • Use GWiki Fragments to embedd editable parts in the Wicket page.
  • Use GWiki to manage HTML files used by Wicket as template to render the view.

Content Management

  • Manage online Help, FAQ, etc.
  • Manage files.

Developing Applications

GWiki can be used as rapid development plattform.

  • Create dynamic web applications without need of an additionally framework.
  • Create online modification without need of redeployment.
  • Track modification with integrated version management.

Developing GWiki

Future plans in GWiki Development.

Developing GWiki Improvments

  • GUI polishing
  • Editor refinements
  • Rich Text Editor
  • User Managment.

Developing GWiki New Core Features

  • Database support for more data bases like PosteSQL, MS SQL, mySQL. Please leave a message.
  • Support something like a draft version. Include a release mechanism for publish drafts.
  • Integrate versioned ClassLoader (genome)
  • Improved User Management
  • Drop in Plugins
  • Better Document generation process (PDF, Word)

Developing GWiki Web 2.0

  • RSS/Atom Feeds
  • Inter-Wiki Links / Backtrack links.
  • Wiki as Google App
  • Portlet

Developing GWiki Ad Ons

  • Macros, Skins, Macros, Macros
  • Blog Plugin. Integrate Blog in GWiki just with a macro. The work is already started, but not finished yet.
  • Forum Plugin. Create Forums inside GWiki.
  • Virtual Content Folder Macro: To integrate external HTML files - for example Java Doc and own gwiki element will be provided.

Developing GWiki Cloud

  • Wiki as Service
  • Virtualize GWiki instances
  • Distributed Wikis.


Last modified 2010-08-31 16:42 by rkommer (ViewCount: 874 ) By Roger Rene Kommer and Micromata GmbH | License