iobataya / dokuwiki-plugin-tabinclude

Tab control for DokuWiki
3 stars 5 forks source link

tabinclude and templates #41

Open roadrunnerjb opened 9 years ago

roadrunnerjb commented 9 years ago

Hi,

I'm relatively new to dokuwiki and found some useful plugins the tabinclude and the https://www.dokuwiki.org/plugin:templater plugin.

Now I want to combine the two plugins having a template set of pages (each tab represented by a template page) and filled with parameters.

I tried to combine the Syntax:

{{tablink>{{template>tpl:aufgaben|aufgabe=xxx|url=na}},{{template>tpl:files|files=xx}}}}

but without success.

Is this possible, is there another way to achive what I want to get ?

may be having the following Syntax:

{{tablink>tpl:aufgabe|aufgabe=xxx|url=xxx,tpl:files|files=xxx,...}}

Regards

iobataya commented 9 years ago

Hi, I'm afraid it's impossible to combine these plugins. Tabinclude plugin show pages defined by their page names identifying them (IDs). On the other hand, templater plugin put out contents whose texts replaced by arguments. The contents is not pagename or IDs. If tabinclude accepts such contents, I think consistency of syntax will be lost to make users confused.

What you want to do is accomplished by making intermediate wiki pages. {{tablink>aufgabe1,filelist}} where

roadrunnerjb commented 9 years ago

Hi, thx for your suggestion, that's what I found out too. But I have more than 100 main pages using about 7 tabs, means to create (and maintain) over 700 pages manually...

iobataya commented 9 years ago

700 pages manually !

I suppose there's a possibility to implement such replacing function in this plugin without keeping compatibility. This plugin has alternative syntax (https://www.dokuwiki.org/plugin:tabinclude#alternative_syntax) splitted by linefeed. Perhaps this syntax can accept some options like,

<tabbed>
  *page1 replace(a=xx|b=yy)
  *page2 replace(a=xx|b=yy)
  *...
</tabbed>
roadrunnerjb commented 9 years ago

Hi iobataya,

this option sounds great and will save me lot's of work. How can I achive/support this ? I'm not familliar with php but if you can support me I will test an perhaps write some docu/examples on this.