The ideashow tag is used like this:
{% ideashow %}
<div id="{{ id.feedback }}">
...
<a onclick="{{ action.positive }}">...</a>
...
</div>
{% endideashow %}
This special tag assists with voting on ideas. It works similarly to the [[Comment Show tag]] but is much simpler.
The id object has a number of attributes which are HTML ids for various elements that are required to have certain names in order to function with the [[public.js]] javascript library.
| Attribute | Description |
| feedback | This is the container of the feedback area, the links that will vote the idea up/down. |
| flagging | This is the container of the “Flag for editor attention” link. |
| positives_count | The container for the ‘1 person’ or ‘2 people’ part of the number of people who liked this idea. |
| negatives_count | The container for the ‘1 person’ or ‘2 people’ part of the number of people who disliked this idea. |
Note that on ideas, we normally show the positive and negative votes separately, whereas for comments we show the sum.
The action object has a number of attributes that do javascript calls to [[public.js]] in response to a user’s interaction with the idea.
| Attribute | Description |
| positive | Will submit a positive vote for this idea, update the ‘id.positives_count’ container with the new count, and add a ‘voted’ class to the ‘id.feedback’ container, and a ‘flagged’ class to the ‘id.flagging’ container, so the positive/negative/flag buttons can be grayed out. You can only vote once on a given idea. |
| negative | Will submit a negative vote for this idea, update the ‘id.negatives_count’ container with the new count, and add the same classes as ‘action.positive’. |
| flag | Will flag this idea for editorial attention. Adds the same classes as ‘action.positive’ |