I'm trying to set up templates that can automatically generate gantt charts based on inputs, but there seem to be fundamental compatibility problems.
- Template variables are not accepted as inputs, and seem to cause "Fatal error: Call to a member function getElementsByTagName() on a non-object"
- Magic words and parser functions cause the same phenomenon
- Templates containing task entries (like one template per task declaration) are discarded
- My only success has been including the entire block of code in a single template, including the opening and closing tags, with all hard-coded values; this transcludes normally
My ultimate objective is get this extension running in a Semantic Mediawiki environment, to generate Gantt charts based on the outputs of #ask queries, but that means each line of the chart needs to be packaged as an individual template, and the values delivered to it as template variables. There was once an extension that did this automatically, but it has been mothballed.
What I need to be able to do is something like this:
Template:EQDD contributor tracker gantt chart/row <includeonly> <task> <pID>{{#vardefineecho: taskid | {{#expr: {{#var:taskid}} + 10 }} }}</pID> <pName>{{{2|}}}</pName> <pStart>{{#dateformat: {{{3|}}} |ISO 8601}}</pStart> <pEnd>{{#dateformat: {{{4|}}} |ISO 8601}}</pEnd> <pColor>36b</pColor> <pLink>{{canonicalurl: {{{1|}}} }}</pLink> </task> </includeonly>
Please advise.
MW 1.25.2
PHP 5.5.38
MySQL 5.7.20-log
SMW 2.5.6
~ Michael Chidester (Contact) 20:07, 24 October 2018 (UTC)