wiki:IncludeMacro

Version 4 (modified by coderanger, 6 years ago) (diff)

--

Include external resources in a wiki page.

Description

This macro lets you include things into wiki pages.

Currently supported sources are:

  • HTTP - http: and https:
  • 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 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

[14141] by hasienda on 2014-08-31 00:05:39
IncludeMacro: Resolve relative wiki page references, refs #3591.
[13471] by rjollos on 2013-12-11 07:30:16
Allow source aliases browser and repos.
[13470] by rjollos on 2013-12-11 07:30:13
Allow source aliases browser and repos.

Author/Contributors

Author: coderanger
Contributors: