2

My Wiki Article Index plugin implements an insertable table of contents of all articles for a given Wiki.

One of my users would like to create a wiki template that shows the article index to the left of each article, but I can't figure out a way to instruct them to include the wiki-block within a template.

I tried inserting the markup that I pulled from the sBody field of the WikiArticle table manually, but it didn't replace it with the wiki block content.

<input plugin_type="toc" 
       plugin_data="{'fIncludeH6':'True', 'fIncludeH1':'True', 
                    'fIncludeH4':'True', 'Version':'0', 
                    'fIncludeH5':'True', 'fIncludeH2':'True','
                     fIncludeH3':'True'}" plugin_content="" 
       type="hidden" />

Is there any way to insert a wiki block into a template?

Fog Creek Case FC1456364

flag

3 Answers

2

It is now possible to do this in FogBugz 8!

While there isn't a generalized method for inserting arbitrary wiki blocks into wiki templates, plugins now have the ability to provide their own custom template placeholders.

The latest version of the Wiki Article Table of Contents plugin now provides a $toc$ placeholder that can be included in your wiki templates.

Note for plugin developers: This ability is exposed via the new IPluginWikiTemplatePlaceholder interface.

link|flag
Awesome. I was just about to update that plugin too. – JohnFx Sep 11 2010 at 20:35
2

No, but it's a good idea and I have linked this discussion to our case for making wiki templates more plugin-accessible. Right now an index index on every page would probably have to be presented as an option within the plugin and achieved using IPluginWikiPageDisplay directly.

link|flag
1

I am doing what your user wants with a page I create manually (it's displayed in a div to the left of every article in a Wiki). It should work with a page created by the index plug in, shouldn't it? Insert the index table in a single page and use it as the source.

The index table is served up in a div with id="WikiArticleIndex". Some BugMonkey script should be able to get the page containing the index, strip out the WikiArticleIndex div, and put it where-ever the template wants it... no?

see http://fogbugz.stackexchange.com/questions/59/bugmonkey-scripts-post-them-here/1020#1020

link|flag
Nice. I like it. – JohnFx Apr 14 2010 at 18:31

Your Answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.