wiki:WikiIncludePlugin

Wiki Include Plugin

Description

When the standard WikiInclude macro is used, occasionally an error is displayed. Please see MacroMigrationTutorial for the reasons.

This plugin offers the same functionality, but without issuing an error.

Bugs/Feature Requests

Existing bugs and feature requests for WikiIncludePlugin are here.

If you have any issues, create a new ticket.

defect

3 / 3

enhancement

0 / 6

task

0 / 1

Download

Download the source from here.

Source

You can check out WikiIncludePlugin from here using Subversion, or browse the source with Trac.

Installation

  • Build the egg file following the plugin packaging instructions.
  • Copy the dist/WikiIncludePlugin-0.y.z-py2.3.egg file in your plugins project directory.
  • Requires the following setup in your trac.ini file:
    [components]
    wikiinclude.* = enabled
    
  • If you are using the WikiInclude macro, you need to remove wiki-macros/WikiInclude.py.

Example

[[WikiInclude(Foo)]]
[[WikiInclude(Foo|Argument1|Argument2..|ArgumentN)]]

Version 0.2 (see attachment) with possibility to include specific page version:

[[WikiInclude(Specification?version=7)]]

Recent Changes

15264 by rjollos on 2016-02-11 05:22:34
Remove unnecessary svn:mime-type on py files

svn:mime-type was set to "plain" for many files.

9581 by rjollos on 2010-12-04 16:01:11
Add 0.11 version to repository, previously attached to wiki page, and patch setup.py. Fixes #3428.
141 by yu-ji on 2005-11-21 10:37:39
WikiIncludePlugin:

Invalid description, fix it.

(more)

Author/Contributors

Author: yu-ji
Maintainer: yu-ji
Contributors: bubacoo

Wiki Variable

Contribution by mdelorme

I updated the script to be able to use Wiki Variables (think report variables):

 for arg in args:
         text = text.replace('{{%d}}' % (i+1), args[i])
         i += 1
 for arg in req.args:
         text = text.replace('{{%s}}' % arg, req.args[arg])

You use it like this: You call your page my_trac.com/wiki/my_page?FOO=1234, then in my_page :

Lorem impsum ...
[[WikiInclude(Foo)]]
....

and then in Foo you could use FOO like this:

bla bla bla {{FOO}} bla bla {{1}} blabla bla blabla bla bla 
Last modified 11 months ago Last modified on Nov 19, 2015, 10:01:31 AM