Menu

Commit [r8697]  Maximize  Restore  History

Add a simple syntax for defining anchors anywhere in wiki pages:

{{{
[=#point1]
}}}

The syntax is reminiscent of the syntax used for adding explicit ids to headings:
{{{
== Long title == #title
}}}

It's also very close to the syntax for the corresponding ''link'' to that anchor:
{{{
[#point1]
}}}

Optionally, a label can be given to the anchor:
{{{
[[=#point1 '''Point 1''']]
}}}

For more complex anchors (e.g. when a custom title is wanted), one can use the Span macro, e.g. `[[span(id=point1, class=wikianchor, title=Point 1, ^(1)^)]]`.

Closes #6413.

cboos 2009-10-26

changed /trunk/trac/htdocs/css/trac.css
changed /trunk/trac/wiki/formatter.py
changed /trunk/trac/wiki/parser.py
changed /trunk/trac/wiki/templates/wiki_view.html
changed /trunk/trac/wiki/tests/wiki-tests.txt
/trunk/trac/htdocs/css/trac.css Diff Switch to side-by-side view
Loading...
/trunk/trac/wiki/formatter.py Diff Switch to side-by-side view
Loading...
/trunk/trac/wiki/parser.py Diff Switch to side-by-side view
Loading...
/trunk/trac/wiki/templates/wiki_view.html Diff Switch to side-by-side view
Loading...
/trunk/trac/wiki/tests/wiki-tests.txt Diff Switch to side-by-side view
Loading...
MongoDB Logo MongoDB