This question is locked. New answers and comments are not allowed.
I am trying to create a collapsible div inside a template. It won't work.
Basically the logic is like this....
<script type="text/x-kendo-template" id="workshopslist-listview-template">
<h3>${name}</h3>
# var _d = description; var _d_short = _d.substring(0,20); #
# if (_d.length>40) { #
<div id="${id}_ch" style="color:#00CCFF;display:block;" data-click="toggle" data-parmid="${id}">
<h4> #: _d_short #...</h4>
</div>
<div id="${id}_cc" style="display:none;" data-click="toggle" data-parmid="${id}">
<p>#: _d #</p>
</div>
# } else { #
<p>#: _d #</p>
# } #
<p>${other}</p>
</script>
My attempts are frustrated in that I can't find any serious documentation on template processing, using conditional inside a template.
I;ve tried to use <div id="#: id #_ch" style="color:#00CCFF;display:block;" data-click="toggle" data-parmid="#: id #"> but it doesn't work.
Lost
Robert
Basically the logic is like this....
<script type="text/x-kendo-template" id="workshopslist-listview-template">
<h3>${name}</h3>
# var _d = description; var _d_short = _d.substring(0,20); #
# if (_d.length>40) { #
<div id="${id}_ch" style="color:#00CCFF;display:block;" data-click="toggle" data-parmid="${id}">
<h4> #: _d_short #...</h4>
</div>
<div id="${id}_cc" style="display:none;" data-click="toggle" data-parmid="${id}">
<p>#: _d #</p>
</div>
# } else { #
<p>#: _d #</p>
# } #
<p>${other}</p>
</script>
My attempts are frustrated in that I can't find any serious documentation on template processing, using conditional inside a template.
I;ve tried to use <div id="#: id #_ch" style="color:#00CCFF;display:block;" data-click="toggle" data-parmid="#: id #"> but it doesn't work.
Lost
Robert