Edgewall Software

Ticket #1376 (new enhancement)

Opened 4 years ago

Last modified 2 years ago

Alternate Template for wiki pages

Reported by: amasiar@… Owned by:
Priority: normal Milestone: 2.0
Component: wiki system Version: 0.8.1
Severity: normal Keywords:
Cc:

Description

Alternate templates for wiki pages could come really handy when you need to format the wiki text for the end users. For example users can click on a help button and the we can pop up a small window with documentation without any trac navbar or edit buttons.

Also, this would allow to separate "Project Page" with project description wiki pages and "Developer Page" with all the power of trac.

Attachments

Change History

Changed 4 years ago by cboos

  • owner changed from jonas to cboos
  • status changed from new to assigned
  • severity changed from normal to enhancement

I have similar wishes, but how to implement it?

One way would be to subclass the WikiModule, the other other would be more flexible, using is-a relations (relationships are not yet available on the trunk, but on the xref-branch).

In your example, you would prepare a ProjectPage which would be the template for all your project pages, E.g. if TestProject is-a ProjectPage, then it will be displayed according to what is specified in the ProjectPage:

use_template: ProjectPage/ClearSilver
new_window: true
initial_content: Describe your project here

The above syntax is not really pretty, of course.

While browsing the ProjectPage, there should be a form enabling the creation of a new Project...

Changed 4 years ago by cboos

I recently came across another Wiki system (was it MoinMoin?) that allows you to choose a template when creating a new wiki page.

I think that's good and the way it should be: while creating the initial revision of a page, one should be able to select the template to use (none by default).

Once a given XyzTemplate is chosen, an is-a relationship is created from the new page to that XyzTemplate page.

The template drop-down box is created out of all the available template pages (i.e. the all pages that have a is-a relationship to the TemplateTemplate page, plus the TemplateTemplate page itself for creating new templates).

Changed 3 years ago by cmlenz

  • component changed from general to wiki

Changed 2 years ago by sid

Look like a duplicate of #962.

A patch to do this was applied in r3881 (in 0.11) (you can now use the PageTemplates/ prefix for a wiki page to specific a template).

Changed 2 years ago by cboos

Sorry, I think the confusion comes from my comments above, which mixed the original request with the idea of PageTemplates.

PageTemplates are effectively implemented for 0.11, but it's still not possible to specify an alternate display style for a given page.

Changed 2 years ago by cboos

  • owner cboos deleted
  • status changed from assigned to new
  • milestone set to 2.0

Add/Change #1376 (Alternate Template for wiki pages)

Author



Change Properties
<Author field>
Action
as new
as The resolution will be set. Next status will be 'closed'
to The owner will change from (none). Next status will be 'new'
The owner will change from (none) to anonymous. Next status will be 'assigned'
 
Note: See TracTickets for help on using tickets.