wiki:IncludeMacro

Version 3 (modified by Noah Kantrowitz, 17 years ago) (diff)

Add permissions notice

Include external resources in a wiki page.

Description

This macro lets you include things into wiki pages.

Currently supported sources are:

  • HTTP - http:
  • FTP - ftp:
  • Wiki pages - wiki:
  • Repository files - source:

An optional second argument lets you force the output MIME type to something specific, but most things should have sane defaults.

For URL includes (HTTP and FTP) you need the permission INCLUDE_URL. For other internal resources you need the normal Trac permission to access it.

Bugs/Feature Requests

Existing bugs and feature requests for IncludeMacro are here.

If you have any issues, create a new ticket.

Download

Download the zipped source from [download:includemacro here].

Source

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

Example

Include Google on a page:

[[Include(http://www.google.com)]]

Include a wiki-formatted file from the repository:

[[Include(source:trunk/my_file.txt, text/x-trac-wiki)]]

Recent Changes

18505 by rjollos on 2023-02-22 01:16:00
TracIncludeMacro 3.3.0dev: Fix typo in r18147

Patch by figaro.

Fixes #14199.

18147 by Cinc-th on 2021-04-04 12:26:27
IncludeMacro: fixes for Python 3 support. The macro now works with Trac 1.5/Trac 1.6.
18132 by rjollos on 2021-04-01 19:57:18
TracIncludeMacro 3.3.0dev: Fix ReST formatting
(more)

Author/Contributors

Author: coderanger
Contributors: